A simple CLI tool written to verify files based on various hashing algorithms.
Hashmatch is cross platform and available on Linux, macOS and Windows.
- Install on macOS via Homebrew
brew install agrimrules/hashmatch/hashmatch
- Install on Windows via Scoop
scoop bucket add agrimrules https://github.com/agrimrules/scoop-bucket.git
scoop install agrimrules/hashmatch
- Install via the golang toolchain
go get -u github.com/agrimrules/hashmatch
- Binaries are available at the Releases page, download the necessary binary for your platform and add it to your
$PATH
hashmatch file1 --hash crc32
Is used to return the hash value of the particular file using the specified algorithm (default: md5sum, options: sha1, sha256, crc32)
hashmatch file1 file2
Can be used to see if both files are the same via matching md5 sums
hashmatch /path/to/directory1 /path/to/directory2
Will traverse both directories and indicate if all files within them match or not.
hashmatch file1 -o json
The -o
flag can be used to output the results in JSON format
The Hashmatch cli tool is open-sourced software licensed under the Apache-2.0 License.
The following projects had particular influence on the hashmatch cli.
- karrick/godirwalk helped provide quick directory traversal using a simpler API.
- olekukonko/tablewriter Provides a simple table TUI for displaying the results of the comparison.
- spf13/cobra A Go framework for building CLI applications.
- thoas/go-funk A Go library providing functional utilities similar to lodash.