diff options
Diffstat (limited to 'ext/installfiles')
-rw-r--r-- | ext/installfiles/mac/install.tmpl.sh | 2 | ||||
-rwxr-xr-x | ext/installfiles/mac/launch.sh | 2 | ||||
-rwxr-xr-x | ext/installfiles/mac/uninstall.sh | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/ext/installfiles/mac/install.tmpl.sh b/ext/installfiles/mac/install.tmpl.sh index 87addba5..e65e71c1 100644 --- a/ext/installfiles/mac/install.tmpl.sh +++ b/ext/installfiles/mac/install.tmpl.sh @@ -23,7 +23,7 @@ if [ $dryRun -gt 0 ]; then fi zthome="/Library/Application Support/ZeroTier/One" -ztapp=`mdfind kMDItemCFBundleIdentifier == 'com.zerotier.ZeroTierOne'` +ztapp=`mdfind kMDItemCFBundleIdentifier == 'com.zerotier.ZeroTierOne' | sort | head -n 1` if [ ! -d "$ztapp" ]; then ztapp="/Applications/ZeroTier One.app" fi diff --git a/ext/installfiles/mac/launch.sh b/ext/installfiles/mac/launch.sh index dc7c2229..371b3f5d 100755 --- a/ext/installfiles/mac/launch.sh +++ b/ext/installfiles/mac/launch.sh @@ -2,7 +2,7 @@ zthome="/Library/Application Support/ZeroTier/One" export PATH="/bin:/usr/bin:/sbin:/usr/sbin:$zthome" -ztapp=`mdfind kMDItemCFBundleIdentifier == 'com.zerotier.ZeroTierOne'` +ztapp=`mdfind kMDItemCFBundleIdentifier == 'com.zerotier.ZeroTierOne' | sort | head -n 1` # Clean all other stuff off the system if the user has trashed the .app if [ -z "$ztapp" -o ! -d "$ztapp" ]; then diff --git a/ext/installfiles/mac/uninstall.sh b/ext/installfiles/mac/uninstall.sh index 73eac91d..d1e9a513 100755 --- a/ext/installfiles/mac/uninstall.sh +++ b/ext/installfiles/mac/uninstall.sh @@ -3,7 +3,7 @@ export PATH=/bin:/usr/bin:/sbin:/usr/sbin zthome="/Library/Application Support/ZeroTier/One" -ztapp=`mdfind kMDItemCFBundleIdentifier == 'com.zerotier.ZeroTierOne'` +ztapp=`mdfind kMDItemCFBundleIdentifier == 'com.zerotier.ZeroTierOne' | sort | head -n 1` if [ "$UID" -ne 0 ]; then echo "Must be run as root; try: sudo $0" |