summaryrefslogtreecommitdiff
path: root/scripts/sha256sum
blob: da34d91134129c02f97a8a6cd24447ac71043c90 (plain)
1
2
3
4
5
6
7
8
9
10
11
#!/usr/bin/env bash
# This file is part of the OpenADK project. OpenADK is copyrighted
# material, please see the LICENCE file in the top-level directory.

if [ -x /usr/bin/sha256sum ]; then
	/usr/bin/sha256sum "$@"
else
	tmp=$(mktemp -t yyy)
	cat - > $tmp
	shasum -a 256 "$@" $tmp
fi