file-hasher
Compute file checksums (MD5, SHA-1, SHA-256) and verify file integrity. Use when you need to verify file integrity, detect duplicates, or generate hash identifiers for digital assets.
File Hasher
Quickly compute and verify file hashes. Supports MD5, SHA-1, and SHA-256.
Prerequisites
sha256sum,sha1sum,md5sumavailable on PATH (standard on Linux/macOS)
Usage
Compute a single hash
bash scripts/hash.sh <file> [algorithm]
algorithm:sha256(default),sha1, ormd5
Compute all algorithms at once
bash scripts/hash-all.sh <file>
Verify a hash
bash scripts/verify.sh <file> <expected-hash> [algorithm]
Exit code 0 = match, 1 = mismatch.
Examples
# SHA-256 of a file
bash scripts/hash.sh ./photo.jpg sha256
# All hashes
bash scripts/hash-all.sh ./document.pdf
# Verify MD5
bash scripts/verify.sh ./data.zip abc123def456 md5
- Downloads
- Security audit
- Pass
- Last updated
- 3mo ago
- Current version
- v1.0.0
- License
- MIT-0
