Crates.io | sqlar |
lib.rs | sqlar |
version | 1.0.0 |
source | src |
created_at | 2021-04-09 18:48:34.67313 |
updated_at | 2022-08-15 20:52:33.620349 |
description | Port of the SQLite Archive Files utility |
homepage | |
repository | https://github.com/badboy/sqlar-rs |
max_upload_size | |
id | 381419 |
size | 41,078 |
An "SQLite Archive" is a file container similar to a ZIP archive or Tarball but based on an SQLite database.
See the SQLite Archive Files documentation for all information.
This library allows to list archive contents, extract files from archives or create a new
archive.
It's main usage is throug the command line utility sqlar
.
The command line utility sqlar
can be installed through cargo
:
cargo install sqlar
sqlar l path/to/file.sqlar
sqlar x path/to/file.sqlar path/to/dest/
sqlar c path/to/new-archive.sqlar path/to/source/
The library can also be used progamatically.
use sqlar::with_each_entry;
with_each_entry("path/to/archive.sqlar", false, |entry| {
println!("File: {}, file type: {:?}, mode: {}", entry.name, entry.filetype, entry.mode);
Ok(())
});
use sqlar::create;
create("path/to/new-archive.sqlar", &["path/to/source"]);
use sqlar::extract;
extract("path/to/archive.sqlar", "path/to/dest");
MIT. See LICENSE.