mirror of
https://github.com/DarrylNixon/melamine.git
synced 2024-04-22 06:27:20 -07:00
Update README
This commit is contained in:
parent
0d61346b3c
commit
73ee192dc3
1 changed files with 35 additions and 2 deletions
37
README.md
37
README.md
|
@ -15,7 +15,7 @@ it runs on linux (Ubuntu tested) for now<br/>
|
||||||
|
|
||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
todo
|
Install using the below command lines to ensure dependencies are met for Ubuntu. `sudo` is currently required.
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
sudo apt install --yes --no-install-recommends build-essential python3-dev libzfslinux-dev && \
|
sudo apt install --yes --no-install-recommends build-essential python3-dev libzfslinux-dev && \
|
||||||
|
@ -23,7 +23,39 @@ sudo pip3 install Cython && \
|
||||||
git clone https://github.com/truenas/py-libzfs && pushd py-libzfs && \
|
git clone https://github.com/truenas/py-libzfs && pushd py-libzfs && \
|
||||||
./configure --prefix=/usr && sudo make install && popd && \
|
./configure --prefix=/usr && sudo make install && popd && \
|
||||||
git clone https://sillyhats.mips.uk/pdf/melamine && pushd melamine && \
|
git clone https://sillyhats.mips.uk/pdf/melamine && pushd melamine && \
|
||||||
python3 -m pip install .
|
sudo python3 -m pip install .
|
||||||
|
```
|
||||||
|
|
||||||
|
Verify the installation with `sudo melamine --help` or `sudo melamine -h` to see:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
usage: melamine [-h] [--recursive] [--yes] [--dryrun] [--exhaustive]
|
||||||
|
[--ignoredir IGNOREDIR] [--logfile LOGFILE] [--quiet]
|
||||||
|
[--verbose]
|
||||||
|
paths [paths ...]
|
||||||
|
|
||||||
|
Comprehensive DoD 5220.22-M-compliant file shredder for Linux.
|
||||||
|
|
||||||
|
positional arguments:
|
||||||
|
paths Specify any number of existing files or directories to
|
||||||
|
be processed.
|
||||||
|
|
||||||
|
options:
|
||||||
|
-h, --help show this help message and exit
|
||||||
|
--recursive, -r Process directories recursively. Default is false.
|
||||||
|
--yes, -y Skip confirmation prompts. Default is false.
|
||||||
|
--dryrun, -d Provide mock output without deleting anything. Default
|
||||||
|
is false.
|
||||||
|
--exhaustive, -e Exhaustively check local mounts for duplicate files by
|
||||||
|
hash. Default is false.
|
||||||
|
--ignoredir IGNOREDIR, -i IGNOREDIR
|
||||||
|
Specify directories to be ignored during the process.
|
||||||
|
This option can be used multiple times.
|
||||||
|
--logfile LOGFILE, -o LOGFILE
|
||||||
|
Specify a file to log all output (NOT IMPLEMENTED).
|
||||||
|
--quiet, -q Silence all output (NOT IMPLEMENTED).
|
||||||
|
--verbose, -v Provide extra output for debugging (NOT IMPLEMENTED).
|
||||||
|
|
||||||
```
|
```
|
||||||
|
|
||||||
## Example
|
## Example
|
||||||
|
@ -38,6 +70,7 @@ rm -rf /tmp/melamine_hardlinks && mkdir -p /tmp/melamine_hardlinks;
|
||||||
for i in $(seq 1 4); do dd if=/dev/urandom of=/tmp/melamine/test_$i bs=1 count=$(( RANDOM % 256 * 256 )); done;
|
for i in $(seq 1 4); do dd if=/dev/urandom of=/tmp/melamine/test_$i bs=1 count=$(( RANDOM % 256 * 256 )); done;
|
||||||
ln /tmp/melamine/test_1 /tmp/melamine_hardlinks/hardlink_1;
|
ln /tmp/melamine/test_1 /tmp/melamine_hardlinks/hardlink_1;
|
||||||
ln /tmp/melamine/test_2 /tmp/melamine_hardlinks/hardlink_2;
|
ln /tmp/melamine/test_2 /tmp/melamine_hardlinks/hardlink_2;
|
||||||
|
melamine --recursive /tmp/melamine
|
||||||
```
|
```
|
||||||
|
|
||||||
You can then confirm that the two hardlink inodes match using `ls -li`.
|
You can then confirm that the two hardlink inodes match using `ls -li`.
|
||||||
|
|
Loading…
Reference in a new issue