Update zoom.sh

This commit is contained in:
wattsy74
2021-09-29 18:18:35 +01:00
parent 1df2c2c692
commit 3f87adc76b

View File

@@ -27,7 +27,7 @@ dnldfile='zoom.pkg'
forceQuit='Y'
logfile="/Library/Logs/ZoomInstallScript.log"
deplog="/var/tmp/depnotify.log"
scriptver="1.0g"
scriptver="1.0h"
architecture=$(/usr/bin/arch)
userAgent="Mozilla/5.0 (Macintosh; Intel Mac OS X ${OSvers_URL}) AppleWebKit/535.6.2 (KHTML, like Gecko) Version/5.2 Safari/535.6.2"
@@ -43,7 +43,7 @@ fi
# To get just the latest version url and number from the download URL
latestver=$(curl -A ${userAgent} ${releaseNotesUrl} | iconv -f windows-1251 | grep -m 1 'Version' | cut -f1 -d'<')
latestver=$(curl -A ${userAgent} ${releaseNotesUrl} | iconv -f windows-1251 | grep -m 1 'Version' | cut -f1 -d' ')
echo "Latest version available is: $latestver"
@@ -57,7 +57,7 @@ fi
# Get the version number of the currently-installed App, if any.
if [[ -e "/Applications/${appName}.app" ]]; then
currentinstalledver=`/usr/bin/defaults read "/Applications/${appName}.app/Contents/Info" CFBundleShortVersionString`
currentinstalledver=$(`/usr/bin/defaults read "/Applications/${appName}.app/Contents/Info" CFBundleShortVersionString` | cut -f1 -d' ')
echo "Current installed version is: $currentinstalledver"
echo "Current installed version is: $currentinstalledver" >> ${logfile}
if [[ $latestver = $currentinstalledver ]]; then