1 unstable release

Uses old Rust 2015

0.1.0 Oct 13, 2019

#27 in #lz4


Used in mozlz4

MIT license

70KB
1K SLoC

C 1K SLoC // 0.2% comments Rust 20 SLoC // 0.7% comments

mozlz4

Decompress / compress mozlz4 files, specifically search.json.mozlz4 in Firefox.

Binaries available here

Usage

$ ./mozlz4 --help
mozlz4 0.1.0
Justin Wong
Decompress and compress mozlz4 files. Overwrites existing files.

USAGE:
    mozlz4.exe [FLAGS] <input> [output]

FLAGS:
    -x, --extract     decompress mozlz4 (default)
    -z, --compress    compress to mozlz4
    -h, --help        Prints help information
    -V, --version     Prints version information

ARGS:
    <input>     input file, - for stdin
    <output>    output file, - for stdout (default)

Examples

Extract search.json.lz4

$ ./mozlz4 search.json.mozlz4 search.json

Compress search.json

$ ./mozlz4 -z search.json search.json.mozlz4

Building

$ cargo build --release

Notes

$ rustc --version
rustc 1.24.0 (4d90ac38c 2018-02-12)

lz4.h and lz4.c copied directly from Mozilla repo

Dependencies

~0.4–325KB