Expand description
§larz
A simple, fast, and efficient file archiver and compressor. larz creates archives in the GNU TAR format, and compresses them using LZ4.
§Usage
§Compression
use larz::compress_archive_memory;
use std::path::PathBuf;
use std::io::StdoutLock;
let paths = vec![PathBuf::from("path/to/file"), PathBuf::from("path/to/directory")];
let output_path = PathBuf::from("path/to/output.larz");
compress_archive_memory::<StdoutLock>(paths, output_path, None);
§Decompression
use larz::extract_archive_memory;
use std::path::PathBuf;
let paths = vec![PathBuf::from("path/to/archive.larz")];
let output_path = PathBuf::from("path/to/output");
extract_archive_memory(paths, output_path);
§Features
safe
- Ensures that compression and decompression are performed in a memory-safe manner. This is enabled by default.streaming
- larz supports streaming compression and decompression using the LZ4 frame format. This means that larz can compress and decompress files with larger sizes, without having to load the entire file into memory. This is enabled by default.
§Installation
Run cargo add larz
to add larz to your Cargo.toml
file.
If you intend on using larz
as a tool, run cargo install larz
.
§License
larz is licensed under the GNU Affero General Public License.
§Contributing
Contributions are welcome! Please see CONTRIBUTING.md
for more information.
§Authors
§Acknowledgements
Functions§
- Archive & compress a file or set of files, in memory
- Archive & compress a file or set of files
- Extract & decompress an existing archive, in memory
- Extract & decompress an existing archive