Skip to content

Commit c251c79

Browse files
committed
Fix pipe in get_sha256
1 parent 36fada6 commit c251c79

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/scripts/unix.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -110,11 +110,11 @@ release_lock() {
110110
# Function to get the SHA256 hash of a string.
111111
get_sha256() {
112112
local input=$1
113-
if command -v sha256sum >/dev/null 2>&1; then
113+
if command -v sha256sum >/dev/null; then
114114
printf '%s' "$input" | sha256sum | cut -d' ' -f1
115-
elif command -v shasum >/dev/null 2>&1; then
115+
elif command -v shasum >/dev/null; then
116116
printf '%s' "$input" | shasum -a 256 | cut -d' ' -f1
117-
elif command -v openssl >/dev/null 2>&1; then
117+
elif command -v openssl >/dev/null; then
118118
printf '%s' "$input" | openssl dgst -sha256 | cut -d' ' -f2
119119
fi
120120
}

0 commit comments

Comments
 (0)