Walks a directory tree and computes SHA256 hashes for every file, producing a sorted manifest of hashes and paths. Useful for verifying file integrity across backups, detecting changes in directory snapshots, or generating checksum manifests for release archives. Outputs in text or JSON format.
SecurityFilesystemHashingCLI
Features
- Recursive SHA256 hashing of all files in a directory
- Sorted output manifest with hash per file
- JSON output for machine consumption
- Output to file or stdout
Flags
| Long | Short | Description |
|---|---|---|
| --version | -V | Show version and license |
| --path | -p | Directory to hash (default .) |
| --output | -o | Output file (default stdout) |
| --json | -j | Output as JSON |
Usage
terminal
$ hashdir -p ./src
$
$ hashdir -p ./backup -o manifest.txt
$
$ hashdir -p ./release --json
Dependencies
Bun runtime — uses built-in crypto module for SHA256
Install
$ curl -LO https://labs.stech-sol.com/downloads/hashdir/0.1.0/hashdir_linux_amd64
$ chmod +x hashdir_linux_amd64
$ # Requires Bun runtime: bun run ./hashdir_linux_amd64
About
Downloads
Verify integrity
SHA256 checksums