mirror of
https://github.com/mtan93/Installomator.git
synced 2026-03-08 05:31:53 +00:00
added more msupdate lines, google chrome update now working, too
This commit is contained in:
@@ -6,8 +6,9 @@
|
|||||||
# 2020 Armin Briegel - Scripting OS X
|
# 2020 Armin Briegel - Scripting OS X
|
||||||
#
|
#
|
||||||
# inspired by the download scripts from William Smith and Sander Schram
|
# inspired by the download scripts from William Smith and Sander Schram
|
||||||
|
# with additional ideas and contribution from Isaac Ordonez, Mann consulting
|
||||||
|
|
||||||
VERSION='20200325'
|
VERSION='20200429'
|
||||||
|
|
||||||
export PATH=/usr/bin:/bin:/usr/sbin:/sbin
|
export PATH=/usr/bin:/bin:/usr/sbin:/sbin
|
||||||
|
|
||||||
@@ -154,7 +155,7 @@ case $identifier in
|
|||||||
expectedTeamID="EQHXZ8M8AV"
|
expectedTeamID="EQHXZ8M8AV"
|
||||||
;;
|
;;
|
||||||
googlechromepkg)
|
googlechromepkg)
|
||||||
name="GoogleChrome"
|
name="Google Chrome"
|
||||||
type="pkg"
|
type="pkg"
|
||||||
downloadURL="https://dl.google.com/chrome/mac/stable/gcem/GoogleChrome.pkg"
|
downloadURL="https://dl.google.com/chrome/mac/stable/gcem/GoogleChrome.pkg"
|
||||||
expectedTeamID="EQHXZ8M8AV"
|
expectedTeamID="EQHXZ8M8AV"
|
||||||
@@ -276,9 +277,9 @@ case $identifier in
|
|||||||
downloadURL="https://go.microsoft.com/fwlink/?linkid=525133"
|
downloadURL="https://go.microsoft.com/fwlink/?linkid=525133"
|
||||||
expectedTeamID="UBF8T346G9"
|
expectedTeamID="UBF8T346G9"
|
||||||
blockingProcesses=( "Microsoft AutoUpdate" "Microsoft Word" "Microsoft PowerPoint" "Microsoft Excel" "Microsoft OneNote" "Microsoft Outlook" "Microsoft OneDrive" )
|
blockingProcesses=( "Microsoft AutoUpdate" "Microsoft Word" "Microsoft PowerPoint" "Microsoft Excel" "Microsoft OneNote" "Microsoft Outlook" "Microsoft OneDrive" )
|
||||||
;;
|
|
||||||
updateTool="/Library/Application Support/Microsoft/MAU2.0/Microsoft AutoUpdate.app/Contents/MacOS/msupdate"
|
updateTool="/Library/Application Support/Microsoft/MAU2.0/Microsoft AutoUpdate.app/Contents/MacOS/msupdate"
|
||||||
updateToolArguments=( --install )
|
updateToolArguments=( --install )
|
||||||
|
;;
|
||||||
microsoftofficebusinesspro)
|
microsoftofficebusinesspro)
|
||||||
name="MicrosoftOfficeBusinessPro"
|
name="MicrosoftOfficeBusinessPro"
|
||||||
type="pkg"
|
type="pkg"
|
||||||
@@ -309,12 +310,16 @@ case $identifier in
|
|||||||
type="pkg"
|
type="pkg"
|
||||||
downloadURL="https://go.microsoft.com/fwlink/?linkid=832978"
|
downloadURL="https://go.microsoft.com/fwlink/?linkid=832978"
|
||||||
expectedTeamID="UBF8T346G9"
|
expectedTeamID="UBF8T346G9"
|
||||||
|
updateTool="/Library/Application Support/Microsoft/MAU2.0/Microsoft AutoUpdate.app/Contents/MacOS/msupdate"
|
||||||
|
updateToolArguments=( --install --apps MSFB16 )
|
||||||
;;
|
;;
|
||||||
microsoftremotedesktop)
|
microsoftremotedesktop)
|
||||||
name="Microsoft Remote Desktop"
|
name="Microsoft Remote Desktop"
|
||||||
type="pkg"
|
type="pkg"
|
||||||
downloadURL="https://go.microsoft.com/fwlink/?linkid=868963"
|
downloadURL="https://go.microsoft.com/fwlink/?linkid=868963"
|
||||||
expectedTeamID="UBF8T346G9"
|
expectedTeamID="UBF8T346G9"
|
||||||
|
updateTool="/Library/Application Support/Microsoft/MAU2.0/Microsoft AutoUpdate.app/Contents/MacOS/msupdate"
|
||||||
|
updateToolArguments=( --install --apps MSRD10 )
|
||||||
;;
|
;;
|
||||||
microsoftteams)
|
microsoftteams)
|
||||||
name="Microsoft Teams"
|
name="Microsoft Teams"
|
||||||
@@ -330,12 +335,16 @@ case $identifier in
|
|||||||
type="pkg"
|
type="pkg"
|
||||||
downloadURL="https://go.microsoft.com/fwlink/?linkid=830196"
|
downloadURL="https://go.microsoft.com/fwlink/?linkid=830196"
|
||||||
teamID="UBF8T346G9"
|
teamID="UBF8T346G9"
|
||||||
|
updateTool="/Library/Application Support/Microsoft/MAU2.0/Microsoft AutoUpdate.app/Contents/MacOS/msupdate"
|
||||||
|
updateToolArguments=( --install --apps MSau04 )
|
||||||
;;
|
;;
|
||||||
microsoftedgeenterprisestable)
|
microsoftedgeenterprisestable)
|
||||||
name="Microsoft Edge"
|
name="Microsoft Edge"
|
||||||
type="pkg"
|
type="pkg"
|
||||||
downloadURL="https://go.microsoft.com/fwlink/?linkid=2093438"
|
downloadURL="https://go.microsoft.com/fwlink/?linkid=2093438"
|
||||||
teamID="UBF8T346G9"
|
teamID="UBF8T346G9"
|
||||||
|
updateTool="/Library/Application Support/Microsoft/MAU2.0/Microsoft AutoUpdate.app/Contents/MacOS/msupdate"
|
||||||
|
updateToolArguments=( --install --apps EDGE01 )
|
||||||
;;
|
;;
|
||||||
microsoftword)
|
microsoftword)
|
||||||
name="Microsoft Word"
|
name="Microsoft Word"
|
||||||
@@ -360,37 +369,22 @@ case $identifier in
|
|||||||
appName="Visual Studio Code.app"
|
appName="Visual Studio Code.app"
|
||||||
blockingProcesses=( Electron )
|
blockingProcesses=( Electron )
|
||||||
;;
|
;;
|
||||||
|
microsoftdefenderatp)
|
||||||
|
name="Microsoft Defender ATP"
|
||||||
|
type="pkg"
|
||||||
|
downloadURL="https://go.microsoft.com/fwlink/?linkid=2097502"
|
||||||
|
expectedTeamID="UBF8T346G9"
|
||||||
|
updateTool="/Library/Application Support/Microsoft/MAU2.0/Microsoft AutoUpdate.app/Contents/MacOS/msupdate"
|
||||||
|
updateToolArguments=( --install --apps WDAV00 )
|
||||||
|
;;
|
||||||
|
|
||||||
# note: there are more available MS downloads to add
|
# msupdate codes from:
|
||||||
# 525133 - Office 2019 for Mac SKUless download (aka Office 365)
|
# https://docs.microsoft.com/en-us/deployoffice/mac/update-office-for-mac-using-msupdate
|
||||||
# 2009112 - Office 2019 for Mac BusinessPro SKUless download (aka Office 365 with Teams)
|
|
||||||
# 871743 - Office 2016 for Mac SKUless download
|
|
||||||
# 830196 - AutoUpdate download
|
|
||||||
# 2069148 - Edge (Consumer Stable)
|
|
||||||
# 2069439 - Edge (Consumer Beta)
|
|
||||||
# 2069340 - Edge (Consumer Dev)
|
|
||||||
# 2069147 - Edge (Consumer Canary)
|
|
||||||
# 2093438 - Edge (Enterprise Stable)
|
|
||||||
# 2093294 - Edge (Enterprise Beta)
|
|
||||||
# 2093292 - Edge (Enterprise Dev)
|
|
||||||
# 525135 - Excel 2019 SKUless download
|
|
||||||
# 871750 - Excel 2016 SKUless download
|
|
||||||
# 869655 - InTune Company Portal download
|
|
||||||
# 823060 - OneDrive download
|
|
||||||
# 820886 - OneNote download
|
|
||||||
# 525137 - Outlook 2019 SKUless download
|
|
||||||
# 871753 - Outlook 2016 SKUless download
|
|
||||||
# 525136 - PowerPoint 2019 SKUless download
|
|
||||||
# 871751 - PowerPoint 2016 SKUless download
|
|
||||||
# 868963 - Remote Desktop
|
|
||||||
# 800050 - SharePoint Plugin download
|
|
||||||
# 832978 - Skype for Business download
|
|
||||||
# 869428 - Teams
|
|
||||||
# 525134 - Word 2019 SKUless download
|
|
||||||
# 871748 - Word 2016 SKUless download
|
|
||||||
|
|
||||||
|
# download link IDs from: https://macadmin.software
|
||||||
# these description exist for testing and are intentionally broken
|
|
||||||
|
|
||||||
|
# these descriptions exist for testing and are intentionally broken
|
||||||
brokendownloadurl)
|
brokendownloadurl)
|
||||||
name="Google Chrome"
|
name="Google Chrome"
|
||||||
type="dmg"
|
type="dmg"
|
||||||
@@ -622,8 +616,10 @@ runUpdateTool() {
|
|||||||
cleanupAndExit 15 "Error running $updateTool"
|
cleanupAndExit 15 "Error running $updateTool"
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
cleanupAndExit 16 "couldn't find $updateTool"
|
echo "couldn't find $updateTool, continuing normally"
|
||||||
|
return 1
|
||||||
fi
|
fi
|
||||||
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -705,11 +701,12 @@ if [[ $(mdfind -count "kMDItemFSName == '$appName' && kMDItemKind == 'Applicatio
|
|||||||
appversion=$(mdls -name kMDItemVersion -raw $installedAppPath )
|
appversion=$(mdls -name kMDItemVersion -raw $installedAppPath )
|
||||||
echo "found app at $installedAppPath, version $appversion"
|
echo "found app at $installedAppPath, version $appversion"
|
||||||
if [[ $DEBUG == 0 ]]; then
|
if [[ $DEBUG == 0 ]]; then
|
||||||
runUpdateTool
|
if runUpdateTool; then
|
||||||
|
cleanupAndExit 0
|
||||||
|
fi # otherwise continue
|
||||||
else
|
else
|
||||||
echo "DEBUG mode enabled, not running update tool"
|
echo "DEBUG mode enabled, not running update tool"
|
||||||
fi
|
fi
|
||||||
cleanupAndExit 0
|
|
||||||
else
|
else
|
||||||
echo "could not determine location of $appName"
|
echo "could not determine location of $appName"
|
||||||
fi
|
fi
|
||||||
|
|||||||
Reference in New Issue
Block a user