🔨 Use brew --prefix

This commit is contained in:
Ben Chatelain 2023-11-25 16:59:53 -07:00
parent bcd2411e5d
commit a14384579e
3 changed files with 3 additions and 10 deletions

View file

@ -10,7 +10,7 @@
CMD_NAME = mas
SHELL = /bin/sh
PREFIX ?= /usr/local
PREFIX ?= $(shell brew --prefix)
# trunk
# SWIFT_VERSION = swift-DEVELOPMENT-SNAPSHOT-2020-04-23-a

View file

@ -13,12 +13,7 @@
ARCH=$(uname -m)
RELEASE=.build/${ARCH}-apple-macosx/release
MAS_VERSION=$(script/version)
if [[ $(uname -m) == 'arm64' ]]; then
PREFIX=/opt/homebrew
else
PREFIX=/usr/local
fi
PREFIX=$(brew --prefix)
while test -n "$1"; do
if [[ "$1" == '--universal' ]]; then

View file

@ -9,10 +9,8 @@
# Override default prefix path with optional 1st arg
if test -n "$1"; then
PREFIX="$1"
elif [[ $(uname -m) == 'arm64' ]]; then
PREFIX=/opt/homebrew
else
PREFIX=/usr/local
PREFIX=$(brew --prefix)
fi
echo "==> 🔥 Uninstalling mas from $PREFIX"