summaryrefslogtreecommitdiffhomepage
path: root/dist-assets/pkg-scripts
diff options
context:
space:
mode:
authorDavid Lönnhager <david.l@mullvad.net>2022-09-27 11:06:46 +0200
committerDavid Lönnhager <david.l@mullvad.net>2022-09-27 15:03:10 +0200
commit4fb1e374476ea6fd166539718be59eec7faf18e1 (patch)
tree2c3e3a5f873ef7ef78c39197da4784047a22ffd9 /dist-assets/pkg-scripts
parent8c4d03d4f31069ba9648ffb22c056185d9706167 (diff)
downloadmullvadvpn-4fb1e374476ea6fd166539718be59eec7faf18e1.tar.xz
mullvadvpn-4fb1e374476ea6fd166539718be59eec7faf18e1.zip
Don't fail if brew is not installed
Diffstat (limited to 'dist-assets/pkg-scripts')
-rwxr-xr-xdist-assets/pkg-scripts/postinstall8
1 files changed, 2 insertions, 6 deletions
diff --git a/dist-assets/pkg-scripts/postinstall b/dist-assets/pkg-scripts/postinstall
index dfbbfe377c..8d5812debe 100755
--- a/dist-assets/pkg-scripts/postinstall
+++ b/dist-assets/pkg-scripts/postinstall
@@ -50,12 +50,8 @@ EOM
ZSH_COMPLETIONS_DIR="/usr/local/share/zsh/site-functions/"
-BREW_PREFIX=$(brew --prefix)
-if [[ "$?" -eq 0 ]]; then
- FISH_COMPLETIONS_DIR="${BREW_PREFIX}/share/fish/vendor_completions.d/"
- if [[ ! -d "$FISH_COMPLETIONS_DIR" ]]; then
- FISH_COMPLETIONS_DIR="/usr/local/share/fish/vendor_completions.d/"
- fi
+if [[ -d "/opt/homebrew/share/fish/vendor_completions.d/" ]]; then
+ FISH_COMPLETIONS_DIR="/opt/homebrew/share/fish/vendor_completions.d/"
else
FISH_COMPLETIONS_DIR="/usr/local/share/fish/vendor_completions.d/"
fi