Example compression/decompression CLI software based on the huff_coding crate.
txt
huff [FLAGS] [OPTIONS] <SRC_FILE> [DST_FILE]
txt
<SRC_FILE>
<DST_FILE> [default: ./SRC_FILE.hff]
txt
-b, --block-size <SIZE>
Set how many bytes can be loaded from the file at one time
Possible units:
K/Ki -> Kilobytes/Kibibytes
M/Mi -> Megabytes/Mebibytes
G/Gi -> Gigabytes/Gibibytes
[default: 2G]
```txt
-d, --decompress
Decompresses the hff SRCFILE into DSTFILE.hff
-n, --noask
Omits asking if should replace existing DST_FILE
-r, --replace
Deletes SRC_FILE upon completion
-t, --time
Prints how long it took to finish
-h, --help
Prints help information
-V, --version
Prints version information
```
The hff file format is encoded as follows:
HuffTree
's padding bitsHuffTree
HuffTree
, used to compress the file,
represented in binary (see HuffTree::try_from_bin
)