From b594537ffe65b96504650ecc37764f55e00c341d Mon Sep 17 00:00:00 2001 From: Zach Brown <1254957+zachbr@users.noreply.github.com> Date: Tue, 29 Dec 2015 23:55:44 -0600 Subject: [PATCH] Basic OS X compatibility: It works --- remap.sh | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/remap.sh b/remap.sh index 3afed48da7..3bd79f3ba2 100755 --- a/remap.sh +++ b/remap.sh @@ -21,6 +21,13 @@ if [ ! -f "$jarpath.jar" ]; then fi fi +# OS X doesn't have md5sum, just md5 -r +if [[ "$OSTYPE" == "darwin"* ]]; then + shopt -s expand_aliases + alias md5sum='md5 -r' + echo "Using an alias for md5sum on OS X" +fi + checksum=$(md5sum "$jarpath.jar" | cut -d ' ' -f 1) if [ "$checksum" != "$minecrafthash" ]; then echo "The MD5 checksum of the downloaded server jar does not match the BuildData hash."