mas/script/uninstall

21 lines
326 B
Text
Raw Normal View History

2018-10-17 21:47:08 +00:00
#!/bin/bash -e
#
# script/uninstall
# mas
#
2021-05-07 18:33:39 +00:00
# Removes mas from PREFIX.
#
2018-10-17 21:47:08 +00:00
# Override default prefix path with optional 1st arg
if test -n "$1"; then
2021-03-21 23:50:09 +00:00
PREFIX="$1"
elif [[ $(uname -m) == 'arm64' ]]; then
2021-03-21 23:50:09 +00:00
PREFIX=/opt/homebrew
else
2021-03-21 23:50:09 +00:00
PREFIX=/usr/local
fi
2018-10-17 21:47:08 +00:00
echo "==> 🔥 Uninstalling mas from $PREFIX"
trash "$PREFIX/bin/mas"