diff options
-rwxr-xr-x | kiss | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -107,8 +107,10 @@ hashcheck() { # it outputs a single space between the hash and the file # whereas sha256sum outputs double spaces. It fallbacks to # openssl, but that is rarely ever needed. - { sha256sum "$1" 2>/dev/null || sha256 -r "$1" 2>/dev/null || - openssl dgst -r -sha256 "$1" || die "No sha256 program could be run." ;} | + { sha256sum "$1" 2>/dev/null || + sha256 -r "$1" 2>/dev/null || + openssl dgst -r -sha256 "$1" || + die "No sha256 program could be run." ;} | while read -r hash _; do printf '%s %s\n' "$hash" "$1"; done } |