Crates.io | include_glob |
lib.rs | include_glob |
version | 0.2.0 |
source | src |
created_at | 2023-07-03 20:01:35.808362 |
updated_at | 2023-07-04 10:14:58.584881 |
description | embed files into an executable via glob patterns |
homepage | |
repository | https://github.com/alkarkhi/include_glob |
max_upload_size | |
id | 907415 |
size | 19,363 |
embed files into an executable via glob patterns
include_bytes!
and include_str!
macros behind the scenes.glob
In the command line run:
cargo add include_glob
Assume there is a file file.123.txt
with contents hello world
:
use include_glob::include_glob_bytes;
static FILE: &[u8] = include_glob_bytes!("file.*.txt");
assert_eq!(FILE, b"hello world");
Licensed under either of Apache License, Version 2.0 or MIT license at your option.
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in this crate by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.