hash
Compute hash digests of files or stdin using a selectable algorithm (MD5, SHA-1, SHA-2, BLAKE2b). Returns JSON with per-file digests and byte counts.
Instructions
Compute hash digests of files or stdin with selectable algorithm (MD5, SHA-1, SHA-2, BLAKE2b). Read-only, no side effects. Returns JSON with per-file digests and byte counts. Use when you need flexible algorithm selection from a single tool. Not for fixed-algorithm workflows — use dedicated tools ('md5sum', 'sha256sum', 'b2sum') for consistent output. See also 'md5sum', 'sha256sum', 'b2sum'.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| algorithm | No | Hash algorithm. | sha256 |
| paths | Yes | Files to hash, or '-' for stdin. |