Lightweight multi-file archive format and utilities.
- C++17 compiler
- Boost >= 1.69.0
- lz4 >= 1.9.2 (github.com/lz4/lz4)
The suggested way to use this library and command-line utility is through Conan
Please add the following bintray to your conan remote:
$ conan remote add bintray-shenfy https://api.bintray.com/conan/shenfy/oss
And ask for the latest pagedfile in your project's conanfile.txt:
[requires]
pagedfile/1.3.0@shenfy/testing
or conanfile.py:
requires = "pagedfile/1.3.0@shenfy/testing"
Clone the repository, then install dependencies with conan:
$ mkdir build && cd build
$ conan install ..
You can then either build the library to be exported to your local conan cache:
$ conan build ..
$ conan create .. (user)/(channel)
or build it with cmake and install to your system library folder (default to /usr/local)
$ cmake ../src
$ make -j4
$ make install
If you built with conan, you might want to manually copy the executable pfar to /usr/local/bin.
This is highly discouraged, but should work for now. Please install boost (>=1.69.0) and liblz4 (>=1.9.2) first. Then
$ mkdir build
$ cd build
$ cmake ../src
$ make -j4
$ make install
pfar -a (ARCHIVE_NAME) (INPUT_FILES_AND_FOLDERS)
Example:
$ ls
1.txt 2.txt 3.txt
$ pfar -a test.pf *
Done.
pfar -l (ARCHIVE_NAME)
$ pfar -l test.pf
1.txt (11)
2.txt (11)
3.txt (11)
pfar -d (ARCHIVE_NAME) (FILES_TO_DELETE)
$ pfar -d test.pf 2.txt 3.txt
$ pfar -l test.pf
1.txt (11)
pfar -a (ARCHIVE_NAME) (INPUT_FILES_TO_ADD)
$ pfar -a test.pf 2.txt
$ pfar -l test.pf
1.txt (11)
2.txt (11)
pfar -x (ARCHIVE_NAME) [-o OUTPUT_PATH]
$ mkdir out
$ pfar -x test.pf -o out
Done.
$ ls out/
1.txt 2.txt