#cargo-command #hash-map #base64 #bunch #static #contained #file

app cargo-brust64

cargo command to encode a bunch of static files into base64 and contained in a rust file as Hashmap

4 releases

Uses old Rust 2015

0.1.7 Jan 15, 2021
0.1.6 Dec 15, 2020
0.1.5 Dec 15, 2020
0.1.4 Dec 15, 2020

#489 in Cargo plugins

MIT license

11KB
133 lines

Brust64

A cargo command to encore a bunch of static files into base64 and contained in a rust file as Hashmap.

TODO

  • check extensions (only html, css, js)
  • check errors when calling unwrap()
  • documentation
  • ignore-extension flag
  • extract code from main and create a cli module
  • testing
  • code security (avoid being root from this command), file injection ?

Install

cargo install --path .

Usage

cargo brust64 -d <src_directory> -o file.rs

🏗 WIP...

Dependencies

~24MB
~261K SLoC