Crates.io | archivefs |
lib.rs | archivefs |
version | 1.0.1 |
source | src |
created_at | 2021-04-13 15:58:07.39312 |
updated_at | 2023-11-11 14:32:00.127602 |
description | A read-only FUSE filesystem for mounting compressed archives, inspired by archivemount. |
homepage | |
repository | https://github.com/bugnano/archivefs |
max_upload_size | |
id | 382964 |
size | 42,737 |
Archivefs is a read-only FUSE filesystem for mounting compressed archives, inspired by archivemount.
Archivefs supports all the formats supported by libarchive, including, but not limited to:
Note that libarchive has known bugs when reading rar archives.
fusermount
command (usually provided by the fuse
or fuse2
package)libarchive-dev
or libarchive-devel
package)# This will install only the archivefs executable in $HOME/.cargo/bin, without any
# man page. Also, make sure that the $HOME/.cargo/bin directory is in your PATH
cargo install archivefs
# Alternatively, you can build from source using the command
cargo build --release
# and then copy the file target/release/archivefs somewhere in your PATH
# To build the man page:
a2x -f manpage doc/archivefs.1.adoc
# and then copy the file doc/archivefs.1 in a man path (like $HOME/.local/share/man/man1 )
archivefs [OPTIONS] ARCHIVEPATH MOUNTPOINT
Consider the gzipped tar archive files.tgz
containing files file1
and
file2
, and an empty directory mnt
.
$ ls
files.tgz mnt/
# Mount the archive file
$ archivefs files.tgz mnt
$ ls mnt
file1 file2
# Perform desired read operations on the archive via mnt/
# For example, to extract a file simply copy it
$ cp mnt/file1 ~/
# Unmount the archive when done
$ umount mnt
Contrary to archivemount, which sort-of supports writing to an archive by recreating it, archivefs only supports reading from archives.
Note that if an archive contains hard links, they will be treated as separate files by archivefs.