embed-rust 0.4.0

A macro that allows to embed a Rust executable.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
use embed_rust::embed_rust;

mod utils;

#[test]
fn git_example() {
    const RELATIVE_PATH_SIMPLE_EXAMPLE: &[u8] = embed_rust!({
        path: "projects/relative-path"
    });
    const _: () = assert!(!RELATIVE_PATH_SIMPLE_EXAMPLE.is_empty());
    assert!(utils::contains(
        RELATIVE_PATH_SIMPLE_EXAMPLE,
        b"Hello world from relative path project!"
    ));
}