Skip to content

Include file content with compression in compile time in Rust binary

License

Notifications You must be signed in to change notification settings

DevNulPavel/include_file_compress

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Include file with compile-time compression

This procedural macros includes content of file in your binary with compression at compile time.

It can be useful for including static content of CSS, JS files with compression in compile time.

At this moment deflate compression using flate2 library is supported only.

Example

use include_file_compress::include_file_compress_deflate;

let _compressed =
    include_file_compress_deflate!("data_samples/data.txt", 5);

About

Include file content with compression in compile time in Rust binary

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages