Crates.io | embed-file |
lib.rs | embed-file |
version | 0.2.0 |
source | src |
created_at | 2023-06-06 13:57:45.2775 |
updated_at | 2024-11-09 07:38:32.295728 |
description | Embeds files content into the binary in release mode, but loads it from the fs in debug |
homepage | |
repository | https://github.com/imbolc/embed-file |
max_upload_size | |
id | 883871 |
size | 10,892 |
A simplified version of rust-embed for single files instead of folders. Embeds files content into the binary in release mode, but loads it from the fs in debug.
The goal of is to avoid unnecessary recompilations when an included by e.g. [include_str
]
file change.
let my_string = embed_file::embed_string!("path/to/my-text.txt");
let my_image = embed_file::embed_bytes!("path/to/my-image.jpg");
This project is licensed under the MIT license.