Last active
August 2, 2019 23:43
-
-
Save ywkaras/4c6c43cc785610c350a6221a1aba040d to your computer and use it in GitHub Desktop.
Work-around shasum bash script for Au tests if shasum command missing but sha256sum present
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if [[ -x /usr/bin/shasum ]] ; then | |
/usr/bin/shasum "$@" | |
echo "$?" | |
fi | |
if [[ ( "$1" != "-a" ) || ( "$2" != 256 ) ]] ; then | |
echo "first two parameters must be '-a 256'" 1>&1 | |
exit 1 | |
fi | |
shift 2 | |
sha256sum "$@" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment