From: Thomas Karpiniec Date: Tue, 21 Jan 2020 07:04:34 +0000 (+1100) Subject: Update README with examples and documentation X-Git-Tag: v0.2.0~8 X-Git-Url: https://code.octet-stream.net/hashgood/commitdiff_plain/b33cf19efa79caa5fc84e47e419f107e2311ca67 Update README with examples and documentation --- diff --git a/README.md b/README.md index 295200d..c08c43e 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,49 @@ # hashgood -CLI tool for easily verifying a downloaded file's checksum +A CLI tool for easily verifying a downloaded file's checksum. + +Wouldn't it be nice if your computer compared the hash for you? + +![](img/fail.png) +![](img/maybe.png) + +Read the MD5, SHA1 or SHA256 hash from: + +* Command line argument +* SHASUMS-style check files (`-c`) +* Raw hash in a file/STDIN (`-c`) +* The clipboard (`-p`) + +...or just run `hashgood` against the input and receive all three at once. + +This program arose from dissatisfaction with the [workarounds required for traditional tools](https://thomask.sdf.org/blog/2019/05/05/techniques-for-verifying-shasums-conveniently.html). + +## Compiling + +`hashgood` targets stable Rust. With a Rust toolchain installed, clone the repository and run: + +``` +cargo build --release +``` + +Take the compiled executable from `target/release/hashgood`. + +To include support for pasting from the clipboard with `-p`, specify the extra feature. Note that on Linux this requires several extra libraries: `libxcb1-dev libxcb-xfixes0-dev libxcb-shape0-dev libxcb-render0-dev` + +``` +cargo build --release --features paste +``` + +## Goals + +* Be forgiving and deliver what the user wants with a minimum of fuss. They just want to check this hash, damnit. +* Don't let users be tricked - be explicit about checksum types and the sources of those checksums that are being compared. +* As much cross-platform support as is practical. + +## Non-goals + +* Scriptability. This is an interactive tool. +* Support for any unusual scenarios that could compromise smooth operation. (e.g., text mode, uncommon hash types) + +## Future ideas + +* Nominate a default (downloads) directory and auto-select the most recently created file in that directory as input. diff --git a/img/fail.png b/img/fail.png new file mode 100644 index 0000000..9ff9df9 Binary files /dev/null and b/img/fail.png differ diff --git a/img/maybe.png b/img/maybe.png new file mode 100644 index 0000000..5fcdc64 Binary files /dev/null and b/img/maybe.png differ