Merge branch 'main' into libreoffice

This commit is contained in:
Søren Theilgaard
2022-09-30 22:08:16 +02:00
committed by GitHub
143 changed files with 7003 additions and 922 deletions

View File

@@ -7,6 +7,7 @@ if ! is-at-least 10.14 $installedOSversion; then
exit 98
fi
# MARK: argument parsing
if [[ $# -eq 0 ]]; then
if [[ -z $label ]]; then # check if label is set inside script
@@ -24,7 +25,7 @@ fi
while [[ -n $1 ]]; do
if [[ $1 =~ ".*\=.*" ]]; then
# if an argument contains an = character, send it to eval
printlog "setting variable from argument $1" WARN
printlog "setting variable from argument $1" INFO
eval $1
else
# assume it's a label
@@ -99,6 +100,16 @@ if [[ "$(whoami)" != "root" && "$DEBUG" -eq 0 ]]; then
cleanupAndExit 6 "not running as root, exiting" ERROR
fi
# check Swift Dialog presence and version
DIALOG_CMD="/usr/local/bin/dialog"
if [[ ! -x $DIALOG_CMD ]]; then
# Swift Dialog is not installed, clear cmd file variable to ignore
printlog "SwiftDialog is not installed, clear cmd file var"
DIALOG_CMD_FILE=""
fi
# MARK: labels in case statement
case $label in
longversion)

View File

@@ -1,6 +1,7 @@
wickrme)
# credit: Søren Theilgaard (@theilgaard)
# Label not working, haven't found a solution
name="WickrMe"
printlog "Label for $name broken in test" WARN
type="dmg"
downloadURL=$( curl -fs https://me-download.wickr.com/api/download/me/download/mac | tr '"' '\n' | grep -e '^https://' )
appNewVersion=$( echo ${downloadURL} | sed -E 's/.*\/[a-zA-Z]*-([0-9.]*)\..*/\1/g' )

View File

@@ -1,6 +1,7 @@
wickrpro)
# credit: Søren Theilgaard (@theilgaard)
# Label not working, haven't found a solution
name="WickrPro"
printlog "Label for $name broken in test" WARN
type="dmg"
downloadURL=$( curl -fs https://me-download.wickr.com/api/download/pro/download/mac | tr '"' '\n' | grep -e '^https://' )
appNewVersion=$( echo ${downloadURL} | sed -E 's/.*\/[a-zA-Z]*-([0-9.]*)\..*/\1/g' )

View File

@@ -14,12 +14,15 @@ cleanupAndExit() { # $1 = exit code, $2 message, $3 level
printlog "Debugging enabled, Deleting tmpDir output was:\n$deleteTmpOut" DEBUG
fi
# If we closed any processes, reopen the app again
reopenClosedProcess
if [[ -n $2 && $1 -ne 0 ]]; then
printlog "ERROR: $2" $3
updateDialog "fail" "Error ($1; $2)"
else
printlog "$2" $3
updateDialog "success" ""
fi
printlog "################## End Installomator, exit code $1 \n" REQ
@@ -61,9 +64,12 @@ displaynotification() { # $1: message $2: title
message=${1:-"Message"}
title=${2:-"Notification"}
manageaction="/Library/Application Support/JAMF/bin/Management Action.app/Contents/MacOS/Management Action"
hubcli="/usr/local/bin/hubcli"
if [[ -x "$manageaction" ]]; then
"$manageaction" -message "$message" -title "$title"
elif [[ -x "$hubcli" ]]; then
"$hubcli" notify -t "$title" -i "$message" -c "Dismiss"
else
runAsUser osascript -e "display notification \"$message\" with title \"$title\""
fi
@@ -156,14 +162,22 @@ downloadURLFromGit() { # $1 git user name, $2 git repo name
fi
if [ -n "$archiveName" ]; then
downloadURL=$(curl -L --silent --fail "https://api.github.com/repos/$gitusername/$gitreponame/releases/latest" \
| awk -F '"' "/browser_download_url/ && /$archiveName\"/ { print \$4; exit }")
downloadURL=$(curl -sfL "https://api.github.com/repos/$gitusername/$gitreponame/releases/latest" | awk -F '"' "/browser_download_url/ && /$archiveName\"/ { print \$4; exit }")
if [[ "$(echo $downloadURL | grep -ioE "https.*$archiveName")" == "" ]]; then
printlog "GitHub API not returning URL, trying https://github.com/$gitusername/$gitreponame/releases/latest."
#downloadURL=https://github.com$(curl -sfL "https://github.com/$gitusername/$gitreponame/releases/latest" | tr '"' "\n" | grep -i "^/.*\/releases\/download\/.*$archiveName" | head -1)
downloadURL="https://github.com$(curl -sfL "$(curl -sfL "https://github.com/$gitusername/$gitreponame/releases/latest" | tr '"' "\n" | grep -i "expanded_assets" | head -1)" | tr '"' "\n" | grep -i "^/.*\/releases\/download\/.*$archiveName" | head -1)"
fi
else
downloadURL=$(curl -L --silent --fail "https://api.github.com/repos/$gitusername/$gitreponame/releases/latest" \
| awk -F '"' "/browser_download_url/ && /$filetype\"/ { print \$4; exit }")
downloadURL=$(curl -sfL "https://api.github.com/repos/$gitusername/$gitreponame/releases/latest" | awk -F '"' "/browser_download_url/ && /$filetype\"/ { print \$4; exit }")
if [[ "$(echo $downloadURL | grep -ioE "https.*.$filetype")" == "" ]]; then
printlog "GitHub API not returning URL, trying https://github.com/$gitusername/$gitreponame/releases/latest."
#downloadURL=https://github.com$(curl -sfL "https://github.com/$gitusername/$gitreponame/releases/latest" | tr '"' "\n" | grep -i "^/.*\/releases\/download\/.*\.$filetype" | head -1)
downloadURL="https://github.com$(curl -sfL "$(curl -sfL "https://github.com/$gitusername/$gitreponame/releases/latest" | tr '"' "\n" | grep -i "expanded_assets" | head -1)" | tr '"' "\n" | grep -i "^/.*\/releases\/download\/.*\.$filetype" | head -1)"
fi
fi
if [ -z "$downloadURL" ]; then
cleanupAndExit 9 "could not retrieve download URL for $gitusername/$gitreponame" ERROR
cleanupAndExit 14 "could not retrieve download URL for $gitusername/$gitreponame" ERROR
else
echo "$downloadURL"
return 0
@@ -176,7 +190,8 @@ versionFromGit() {
gitusername=${1?:"no git user name"}
gitreponame=${2?:"no git repo name"}
appNewVersion=$(curl -L --silent --fail "https://api.github.com/repos/$gitusername/$gitreponame/releases/latest" | grep tag_name | cut -d '"' -f 4 | sed 's/[^0-9\.]//g')
#appNewVersion=$(curl -L --silent --fail "https://api.github.com/repos/$gitusername/$gitreponame/releases/latest" | grep tag_name | cut -d '"' -f 4 | sed 's/[^0-9\.]//g')
appNewVersion=$(curl -sLI "https://github.com/$gitusername/$gitreponame/releases/latest" | grep -i "^location" | tr "/" "\n" | tail -1 | sed 's/[^0-9\.]//g')
if [ -z "$appNewVersion" ]; then
printlog "could not retrieve version number for $gitusername/$gitreponame" WARN
appNewVersion=""
@@ -278,7 +293,11 @@ getAppVersion() {
printlog "Replacing App Store apps, no matter the version" WARN
appversion=0
else
cleanupAndExit 1 "App previously installed from App Store, and we respect that" ERROR
if [[ $DIALOG_CMD_FILE != "" ]]; then
updateDialog "wait" "Already installed from App Store. Not replaced."
sleep 4
fi
cleanupAndExit 23 "App previously installed from App Store, and we respect that" ERROR
fi
fi
else
@@ -427,6 +446,7 @@ installAppWithPath() { # $1: path to app to install in $targetDir
# verify with spctl
printlog "Verifying: $appPath" INFO
updateDialog "wait" "Verifying..."
printlog "App size: $(du -sh "$appPath")" DEBUG
appVerify=$(spctl -a -vv "$appPath" 2>&1 )
appVerifyStatus=$(echo $?)
@@ -454,6 +474,10 @@ installAppWithPath() { # $1: path to app to install in $targetDir
printlog "notifying"
displaynotification "$message" "No update for $name!"
fi
if [[ $DIALOG_CMD_FILE != "" ]]; then
updateDialog "wait" "Latest version already installed..."
sleep 2
fi
cleanupAndExit 0 "No new version to install" REG
else
printlog "Using force to install anyway."
@@ -475,7 +499,7 @@ installAppWithPath() { # $1: path to app to install in $targetDir
printlog "notifying"
displaynotification "$message" "Error updating $name!"
fi
cleanupAndExit 6 "Installed macOS is too old for this app." ERROR
cleanupAndExit 15 "Installed macOS is too old for this app." ERROR
fi
fi
@@ -534,7 +558,7 @@ installAppWithPath() { # $1: path to app to install in $targetDir
deduplicatelogs "$CLIoutput"
if [ $CLIstatus -ne 0 ] ; then
cleanupAndExit 3 "Error installing $mountname/$CLIInstaller $CLIArguments error:\n$logoutput" ERROR
cleanupAndExit 16 "Error installing $mountname/$CLIInstaller $CLIArguments error:\n$logoutput" ERROR
else
printlog "Succesfully ran $mountname/$CLIInstaller $CLIArguments" INFO
fi
@@ -572,6 +596,7 @@ installFromDMG() {
installFromPKG() {
# verify with spctl
printlog "Verifying: $archiveName"
updateDialog "wait" "Verifying..."
printlog "File list: $(ls -lh "$archiveName")" DEBUG
printlog "File type: $(file "$archiveName")" DEBUG
spctlOut=$(spctl -a -vv -t install "$archiveName" 2>&1 )
@@ -619,6 +644,10 @@ installFromPKG() {
printlog "notifying"
displaynotification "$message" "No update for $name!"
fi
if [[ $DIALOG_CMD_FILE != "" ]]; then
updateDialog "wait" "Latest version already installed..."
sleep 2
fi
cleanupAndExit 0 "No new version to install" REQ
else
printlog "Using force to install anyway."
@@ -639,8 +668,29 @@ installFromPKG() {
# install pkg
printlog "Installing $archiveName to $targetDir"
pkgInstall=$(installer -verbose -dumplog -pkg "$archiveName" -tgt "$targetDir" 2>&1)
pkgInstallStatus=$(echo $?)
if [[ $DIALOG_CMD_FILE != "" ]]; then
# pipe
pipe="$tmpDir/installpipe"
# initialise named pipe for installer output
initNamedPipe create $pipe
# run the pipe read in the background
readPKGInstallPipe $pipe "$DIALOG_CMD_FILE" & installPipePID=$!
printlog "listening to output of installer with pipe $pipe and command file $DIALOG_CMD_FILE on PID $installPipePID" DEBUG
pkgInstall=$(installer -verboseR -pkg "$archiveName" -tgt "$targetDir" 2>&1 | tee $pipe)
pkgInstallStatus=$pipestatus[1]
# because we are tee-ing the output, we want the pipe status of the first command in the chain, not the most recent one
killProcess $installPipePID
else
pkgInstall=$(installer -verbose -dumplog -pkg "$archiveName" -tgt "$targetDir" 2>&1)
pkgInstallStatus=$(echo $?)
fi
sleep 1
pkgEndTime=$(date "+$LogDateFormat")
pkgInstall+=$(echo "\nOutput of /var/log/install.log below this line.\n")
@@ -732,7 +782,7 @@ installPkgInZip() {
printlog "Found pkg(s):\n$findfiles" DEBUG
filearray=( ${(f)findfiles} )
if [[ ${#filearray} -eq 0 ]]; then
cleanupAndExit 20 "couldn't find pkg in zip $archiveName" ERROR
cleanupAndExit 21 "couldn't find pkg in zip $archiveName" ERROR
fi
# it is now safe to overwrite archiveName for installFromPKG
archiveName="${filearray[1]}"
@@ -745,7 +795,7 @@ installPkgInZip() {
findfiles=$(find "$tmpDir" -iname "$pkgName")
filearray=( ${(f)findfiles} )
if [[ ${#filearray} -eq 0 ]]; then
cleanupAndExit 20 "couldn't find pkg “$pkgName” in zip $archiveName" ERROR
cleanupAndExit 21 "couldn't find pkg “$pkgName” in zip $archiveName" ERROR
fi
# it is now safe to overwrite archiveName for installFromPKG
archiveName="${filearray[1]}"
@@ -768,7 +818,7 @@ installAppInDmgInZip() {
findfiles=$(find "$tmpDir" -iname "*.dmg" -maxdepth 2 )
filearray=( ${(f)findfiles} )
if [[ ${#filearray} -eq 0 ]]; then
cleanupAndExit 20 "couldn't find dmg in zip $archiveName" ERROR
cleanupAndExit 22 "couldn't find dmg in zip $archiveName" ERROR
fi
archiveName="$(basename ${filearray[1]})"
# it is now safe to overwrite archiveName for installFromDMG
@@ -820,7 +870,8 @@ runUpdateTool() {
finishing() {
printlog "Finishing..."
sleep 10 # wait a moment to let spotlight catch up
sleep 3 # wait a moment to let spotlight catch up
getAppVersion
if [[ -z $appversion ]]; then
@@ -868,3 +919,113 @@ hasDisplaySleepAssertion() {
return 1
}
initNamedPipe() {
# create or delete a named pipe
# commands are "create" or "delete"
local cmd=$1
local pipe=$2
case $cmd in
"create")
if [[ -e $pipe ]]; then
rm $pipe
fi
# make named pipe
mkfifo -m 644 $pipe
;;
"delete")
# clean up
rm $pipe
;;
*)
;;
esac
}
readDownloadPipe() {
# reads from a previously created named pipe
# output from curl with --progress-bar. % downloaded is read in and then sent to the specified log file
local pipe=$1
local log=${2:-$DIALOG_CMD_FILE}
# set up read from pipe
while IFS= read -k 1 -u 0 char; do
if [[ $char =~ [0-9] ]]; then
keep=1
fi
if [[ $char == % ]]; then
updateDialog $progress "Downloading..."
progress=""
keep=0
fi
if [[ $keep == 1 ]]; then
progress="$progress$char"
fi
done < $pipe
}
readPKGInstallPipe() {
# reads from a previously created named pipe
# output from installer with -verboseR. % install status is read in and then sent to the specified log file
local pipe=$1
local log=${2:-$DIALOG_CMD_FILE}
local appname=${3:-$name}
while read -k 1 -u 0 char; do
if [[ $char == % ]]; then
keep=1
fi
if [[ $char =~ [0-9] && $keep == 1 ]]; then
progress="$progress$char"
fi
if [[ $char == . && $keep == 1 ]]; then
updateDialog $progress "Installing..."
progress=""
keep=0
fi
done < $pipe
}
killProcess() {
# will silently kill the specified PID
builtin kill $1 2>/dev/null
}
updateDialog() {
local state=$1
local message=$2
local listitem=${3:-$DIALOG_LIST_ITEM_NAME}
local cmd_file=${4:-$DIALOG_CMD_FILE}
local progress=""
if [[ $state =~ '^[0-9]' \
|| $state == "reset" \
|| $state == "increment" \
|| $state == "complete" \
|| $state == "indeterminate" ]]; then
progress=$state
fi
# when to cmdfile is set, do nothing
if [[ $cmd_file == "" ]]; then
return
fi
if [[ $listitem == "" ]]; then
# no listitem set, update main progress bar and progress text
if [[ $progress != "" ]]; then
echo "progress: $progress" >> $cmd_file
fi
if [[ $message != "" ]]; then
echo "progresstext: $name - $message" >> $cmd_file
fi
else
# list item has a value, so we update the progress and text in the list
if [[ $progress != "" ]]; then
echo "listitem: title: $listitem, statustext: $message, progress: $progress" >> $cmd_file
else
echo "listitem: title: $listitem, statustext: $message, status: $state" >> $cmd_file
fi
fi
}

View File

@@ -7,7 +7,7 @@ label="" # if no label is sent to the script, this will be used
# 2020-2021 Installomator
#
# inspired by the download scripts from William Smith and Sander Schram
#
#
# Contributers:
# Armin Briegel - @scriptingosx
# Isaac Ordonez - @issacatmann
@@ -23,7 +23,7 @@ export PATH=/usr/bin:/bin:/usr/sbin:/sbin
# set to 0 for production, 1 or 2 for debugging
# while debugging, items will be downloaded to the parent directory of this script
# also no actual installation will be performed
# debug mode 1 will download to the directory the script is run in, but will not check the version
# debug mode 1 will download to the directory the script is run in, but will not check the version
# debug mode 2 will download to the temp directory, check for blocking processes, check the version, but will not install anything or remove the current version
DEBUG=1
@@ -34,7 +34,6 @@ NOTIFY=success
# - silent no notifications
# - all all notifications (great for Self Service installation)
# behavior when blocking processes are found
BLOCKING_PROCESS_ACTION=tell_user
# options:
@@ -81,6 +80,7 @@ LOGO=appstore
# - mosylem Mosyle Manager (Education)
# - addigy Addigy
# - microsoft Microsoft Endpoint Manager (Intune)
# - ws1 Workspace ONE (AirWatch)
# path can also be set in the command call, and if file exists, it will be used.
# Like 'LOGO="/System/Applications/App\ Store.app/Contents/Resources/AppIcon.icns"'
# (spaces have to be escaped).
@@ -139,6 +139,26 @@ IGNORE_DND_APPS=""
# IGNORE_DND_APPS="firefox,Google Chrome,Safari,Microsoft Edge,Opera,Amphetamine,caffeinate"
# Swift Dialog integration
# These variables will allow Installomator to communicate progress with Swift Dialog
# https://github.com/bartreardon/swiftDialog
# This requires Swift Dialog 2.11.2 or higher.
DIALOG_CMD_FILE=""
# When this variable is set, Installomator will write Swift Dialog commands to this path.
# Installomator will not launch Swift Dialog. The process calling Installomator will have
# launch and configure Swift Dialog to listen to this file.
# See `MDM/swiftdialog_example.sh` for an example.
DIALOG_LIST_ITEM_NAME=""
# When this variable is set, progress for downloads and installs will be sent to this
# listitem.
# When the variable is unset, progress will be sent to Swift Dialog's main progress bar.
# NOTE: How labels work
# Each workflow label needs to be listed in the case statement below.
@@ -184,7 +204,7 @@ IGNORE_DND_APPS=""
# How we get version number from app. Possible values:
# - CFBundleShortVersionString
# - CFBundleVersion
# Not all software titles uses fields the same.
# Not all software titles uses fields the same.
# See Opera label.
#
# - appCustomVersion(){}: (optional function)

View File

@@ -0,0 +1,7 @@
abetterfinderrename11)
name="A Better Finder Rename 11"
type="dmg"
downloadURL="https://www.publicspace.net/download/ABFRX11.dmg"
appNewVersion=$(curl -fs "https://www.publicspace.net/app/signed_abfr11.xml" | xpath '(//rss/channel/item/enclosure/@sparkle:version)' 2>/dev/null | cut -d '"' -f 2)
expectedTeamID="7Y9KW4ND8W"
;;

View File

@@ -0,0 +1,9 @@
acroniscyberprotectconnect|\
remotix)
name="Acronis Cyber Protect Connect"
type="dmg"
downloadURL="https://go.acronis.com/AcronisCyberProtectConnect_ForMac"
versionKey="CFBundleVersion"
appNewVersion=$(curl -fsIL "${downloadURL}" | grep -i "^location" | sed -E 's/.*\/[a-zA-Z]*-[0-9.]*-([0-9.]*)\.dmg/\1/g')
expectedTeamID="ZU2TV78AA6"
;;

View File

@@ -0,0 +1,11 @@
acroniscyberprotectconnectagent|\
remotixagent)
name="Acronis Cyber Protect Connect Agent"
type="pkg"
#packageID="com.nulana.rxagentmac"
downloadURL="https://go.acronis.com/AcronisCyberProtectConnect_AgentForMac"
versionKey="CFBundleVersion"
appNewVersion=$(curl -fsIL "${downloadURL}" | grep -i "^location" | sed -E 's/.*\/[a-zA-Z]*-[0-9.]*-([0-9.]*)\.pkg/\1/g')
expectedTeamID="H629V387SY"
blockingProcesses=( NONE )
;;

View File

@@ -0,0 +1,8 @@
adobeacrobatprodc)
name="Adobe Acrobat Pro DC"
type="pkgInDmg"
downloadURL="https://trials.adobe.com/AdobeProducts/APRO/Acrobat_HelpX/osx10/Acrobat_DC_Web_WWMUI.dmg"
expectedTeamID="JQ525L2MZD"
blockingProcesses=( "Acrobat Pro DC" )
Company="Adobe"
;;

View File

@@ -1,18 +1,24 @@
adobecreativeclouddesktop)
name="Adobe Creative Cloud"
#appName="Install.app"
appName="Install.app"
type="dmg"
adobeurl="https://helpx.adobe.com/download-install/kb/creative-cloud-desktop-app-download.html"
if [[ $(arch) == "arm64" ]]; then
downloadURL=$(curl -fs "$adobeurl" | xmllint -html -xpath "string(//a[contains(@href,'osx10')][contains(text(),'Download')]/@href)" - 2> /dev/null)
elif [[ $(arch) == "i386" ]]; then
downloadURL=$(curl -fs "$adobeurl" | xmllint -html -xpath "string(//a[contains(@href,'macarm64')][contains(text(),'Download')]/@href)" - 2> /dev/null)
if pgrep -q "Adobe Installer"; then
printlog "Adobe Installer is running, not a good time to update." WARN
printlog "################## End $APPLICATION \n\n" INFO
exit 75
fi
#downloadURL=$(curl -fs "https://helpx.adobe.com/download-install/kb/creative-cloud-desktop-app-download.html" | grep -o "https*.*dmg" | head -1)
appNewVersion=$(curl -fs "https://helpx.adobe.com/creative-cloud/release-note/cc-release-notes.html" | grep "mandatory" | head -1 | grep -o "Version *.* released" | cut -d " " -f2)
if [[ "$(arch)" == "arm64" ]]; then
downloadURL=$(curl -fs "https://helpx.adobe.com/download-install/kb/creative-cloud-desktop-app-download.html" | grep -o 'https.*macarm64.*dmg' | head -1 | cut -d '"' -f1)
else
downloadURL=$(curl -fs "https://helpx.adobe.com/download-install/kb/creative-cloud-desktop-app-download.html" | grep -o 'https.*osx10.*dmg' | head -1 | cut -d '"' -f1)
fi
#appNewVersion=$(curl -fs "https://helpx.adobe.com/creative-cloud/release-note/cc-release-notes.html" | grep "mandatory" | head -1 | grep -o "Version *.* released" | cut -d " " -f2)
appNewVersion=$(echo $downloadURL | grep -o '[^x]*$' | cut -d '.' -f 1 | sed 's/_/\./g')
targetDir="/Applications/Utilities/Adobe Creative Cloud/ACC/"
installerTool="Install.app"
CLIInstaller="Install.app/Contents/MacOS/Install"
CLIArguments=(--mode=silent)
expectedTeamID="JQ525L2MZD"
blockingProcesses=( "Creative Cloud" )
Company="Adobe"
;;

View File

@@ -0,0 +1,27 @@
adobereaderdc-install)
name="Adobe Acrobat Reader DC"
type="pkgInDmg"
printlog "Changing IFS for Adobe Reader" INFO
SAVEIFS=$IFS
IFS=$'\n'
versions=( $( curl -s https://www.adobe.com/devnet-docs/acrobatetk/tools/ReleaseNotesDC/index.html | grep -Eo "[0-9]+\.[0-9]+\.[0-9]+"| head -n 30) )
local version
for version in $versions; do
version="${version//.}"
printlog "trying version: $version" INFO
local httpstatus=$(curl -X HEAD -s "https://ardownload2.adobe.com/pub/adobe/reader/mac/AcrobatDC/${version}/AcroRdrDC_${version}_MUI.dmg" --write-out "%{http_code}")
printlog "HTTP status for Adobe Reader full installer URL https://ardownload2.adobe.com/pub/adobe/reader/mac/AcrobatDC/${version}/AcroRdrDC_${version}_MUI.dmg is $httpstatus" DEBUG
if [[ "${httpstatus}" == "200" ]]; then
downloadURL="https://ardownload2.adobe.com/pub/adobe/reader/mac/AcrobatDC/${version}/AcroRdrDC_${version}_MUI.dmg"
unset httpstatus
break
fi
done
unset version
IFS=$SAVEIFS
appNewVersion=$i
expectedTeamID="JQ525L2MZD"
blockingProcesses=( "AdobeReader" )
Company="Adobe"
PatchName="AcrobatReader"
;;

View File

@@ -1,9 +1,44 @@
adobereaderdc-update)
name="Adobe Acrobat Reader DC"
type="pkgInDmg"
downloadURL=$(adobecurrent=`curl --fail --silent https://armmf.adobe.com/arm-manifests/mac/AcrobatDC/reader/current_version.txt | tr -d '.'` && echo https://ardownload2.adobe.com/pub/adobe/reader/mac/AcrobatDC/"$adobecurrent"/AcroRdrDC_"$adobecurrent"_MUI.dmg)
if [[ -d "/Applications/Adobe Acrobat Reader DC.app" ]]; then
printlog "Found /Applications/Adobe Acrobat Reader DC.app"
mkdir -p "/Library/Application Support/Adobe/Acrobat/11.0"
defaults write "/Library/Application Support/Adobe/Acrobat/11.0/com.adobe.Acrobat.InstallerOverrides.plist" ReaderAppPath "/Applications/Adobe Acrobat Reader DC.app"
if ! defaults read "/Applications/Adobe Acrobat Reader DC.app/Contents/Resources/AcroLocale.plist" ; then
printlog "Missing locale data, this will cause the updater to fail. Deleting Adobe Acrobat Reader DC.app and installing fresh." WARN
rm -Rf "/Applications/Adobe Acrobat Reader DC.app"
if [[ $1 == "/" ]]; then
printlog "Running through Jamf: $0." INFO
$0 $1 $2 $3 adobereaderdc-install ${5} ${6} ${7} ${8} ${9} ${10} ${11}
else
printlog "Installomator running locally: $0." INFO
$0 adobereaderdc-install ${2} ${3} ${4} ${5} ${6} ${7} ${8} ${9} ${10} ${11}
fi
fi
fi
adobecurrent=$(curl -sL https://armmf.adobe.com/arm-manifests/mac/AcrobatDC/reader/current_version.txt | tr -d '.')
if [[ "${adobecurrent}" != <-> ]]; then
printlog "Got an invalid response for the Adobe Reader Current Version: ${adobecurrent}" ERROR
printlog "################## End $APPLICATION \n\n" INFO
exit 50
fi
downloadURL=$(echo https://ardownload2.adobe.com/pub/adobe/reader/mac/AcrobatDC/"$adobecurrent"/AcroRdrDCUpd"$adobecurrent"_MUI.dmg)
reader_preinstall() {
if pgrep -a "AdobeReader" >/dev/null 2>&1; then
printlog "AdobeReader is still running, forcefully killing." WARN
killall AdobeReader
fi
}
preinstall="reader_preinstall"
updateTool="/usr/local/bin/RemoteUpdateManager"
updateToolArguments=( --productVersions=RDR )
appNewVersion=$(curl -s https://armmf.adobe.com/arm-manifests/mac/AcrobatDC/reader/current_version.txt)
#appNewVersion=$(curl -s -H "User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15)" https://get.adobe.com/reader/ | grep ">Version" | sed -E 's/.*Version 20([0-9.]*)<.*/\1/g') # credit: Søren Theilgaard (@theilgaard)
updateToolLog="/Users/$currentUser/Library/Logs/RemoteUpdateManager.log"
updateToolLogDateFormat="%m/%d/%y %H:%M:%S"
expectedTeamID="JQ525L2MZD"
blockingProcesses=( "AdobeReader" )
Company=Adobe
PatchName=AcrobatReader
PatchSkip="YES"
;;

View File

@@ -0,0 +1,10 @@
archiwareb2go)
name="P5 Workstation"
type="pkgInDmg"
packageID="com.archiware.presstore"
appNewVersion=$(curl -sf https://www.archiware.com/download-p5 | grep -m 1 "ARCHIWARE P5 Version" | sed "s|.*Version \(.*\) -.*|\\1|")
downloadURL=$(appNrVersion=`sed 's/[^0-9]//g' <<< $appNewVersion` && echo https://p5-downloads.s3.amazonaws.com/awpst"$appNrVersion"-darwin.dmg)
pkgName=$(appNrVersion=`sed 's/[^0-9]//g' <<< $appNewVersion` && echo P5-Workstation-"$appNrVersion"-Install.pkg)
expectedTeamID="5H5EU6F965"
# blockingProcesses=( nsd )
;;

View File

@@ -0,0 +1,10 @@
archiwarepst)
name="P5"
type="pkgInDmg"
packageID="com.archiware.presstore"
appNewVersion=$(curl -sf https://www.archiware.com/download-p5 | grep -m 1 "ARCHIWARE P5 Version" | sed "s|.*Version \(.*\) -.*|\\1|")
downloadURL=$(appNrVersion=`sed 's/[^0-9]//g' <<< $appNewVersion` && echo https://p5-downloads.s3.amazonaws.com/awpst"$appNrVersion"-darwin.dmg)
pkgName=$(appNrVersion=`sed 's/[^0-9]//g' <<< $appNewVersion` && echo P5-"$appNrVersion"-Install.pkg)
expectedTeamID="5H5EU6F965"
# blockingProcesses=( nsd )
;;

View File

@@ -1,7 +1,13 @@
audacity)
name="Audacity"
type="dmg"
downloadURL=$(downloadURLFromGit audacity audacity)
if [[ $(arch) == "arm64" ]]; then
archiveName="audacity-macOS-[0-9.]*-arm64.dmg"
downloadURL=$(downloadURLFromGit audacity audacity)
elif [[ $(arch) == "i386" ]]; then
archiveName="audacity-macOS-[0-9.]*-x86_64.dmg"
downloadURL=$(downloadURLFromGit audacity audacity)
fi
appNewVersion=$(versionFromGit audacity audacity)
expectedTeamID="AWEYX923UX"
;;

View File

@@ -3,5 +3,5 @@ awsvpnclient)
type="pkg"
downloadURL="https://d20adtppz83p9s.cloudfront.net/OSX/latest/AWS_VPN_Client.pkg"
expectedTeamID="94KV3E626L"
appNewVersion=$(curl -is "https://beta2.communitypatch.com/jamf/v1/ba1efae22ae74a9eb4e915c31fef5dd2/patch/AWSVPNClient" | grep currentVersion | tr ',' '\n' | grep currentVersion | cut -d '"' -f 4)
#appNewVersion=$(curl -is "https://beta2.communitypatch.com/jamf/v1/ba1efae22ae74a9eb4e915c31fef5dd2/patch/AWSVPNClient" | grep currentVersion | tr ',' '\n' | grep currentVersion | cut -d '"' -f 4)
;;

View File

@@ -0,0 +1,8 @@
bitrix24)
name="Bitrix24"
type="dmg"
archiveName="bitrix24_desktop.dmg"
downloadURL="https://dl.bitrix24.com/b24/bitrix24_desktop.dmg"
expectedTeamID="5B3T3A994N"
blockingProcesses=( "Bitrix24" )
;;

View File

@@ -2,5 +2,6 @@ boxtools)
name="Box Tools"
type="pkg"
downloadURL="https://box-installers.s3.amazonaws.com/boxedit/mac/currentrelease/BoxToolsInstaller.pkg"
packageID="com.box.boxtools.installer.boxedit"
expectedTeamID="M683GB7CPW"
;;

View File

@@ -0,0 +1,7 @@
carboncopycloner)
name="Carbon Copy Cloner"
type="zip"
downloadURL=$(curl -fsIL "https://bombich.com/software/download_ccc.php?v=latest" | grep -i ^location | sed -E 's/.*(https.*\.zip).*/\1/g')
appNewVersion=$(sed -E 's/.*-([0-9.]*)\.zip/\1/g' <<< $downloadURL | sed 's/\.[^.]*$//')
expectedTeamID="L4F2DED5Q7"
;;

View File

@@ -0,0 +1,7 @@
charles)
name="Charles"
type="dmg"
appNewVersion=$(curl -fs https://www.charlesproxy.com/download/latest-release/ | sed -nE 's/.*version.*value="([^"]*).*/\1/p')
downloadURL="https://www.charlesproxy.com/assets/release/$appNewVersion/charles-proxy-$appNewVersion.dmg"
expectedTeamID="9A5PCU4FSD"
;;

View File

@@ -0,0 +1,11 @@
chronoagent)
name="ChronoAgent"
type="pkgInDmg"
# packageID="com.econtechnologies.preference.chronoagent"
# versionKey="CFBundleVersion"
# None of the above can read out the installed version
releaseURL="https://www.econtechnologies.com/UC/updatecheck.php?prod=ChronoAgent&lang=en&plat=mac&os=10.14.1&hw=i64&req=1&vers=#"
appNewVersion=$(curl -sf $releaseURL | sed -r 's/.*VERSION=([^<]+).*/\1/')
downloadURL="https://downloads.econtechnologies.com/CA_Mac_Download.dmg"
expectedTeamID="9U697UM7YX"
;;

View File

@@ -0,0 +1,8 @@
chronosync)
name="ChronoSync"
type="pkgInDmg"
releaseURL="https://www.econtechnologies.com/UC/updatecheck.php?prod=ChronoSync&lang=en&plat=mac&os=10.14.1&hw=i64&req=1&vers=#"
appNewVersion=$(curl -sf $releaseURL | sed -r 's/.*VERSION=([^<]+).*/\1/')
downloadURL="https://downloads.econtechnologies.com/CS4_Download.dmg"
expectedTeamID="9U697UM7YX"
;;

View File

@@ -1,7 +1,8 @@
clevershare2)
name="Clevershare"
type="dmg"
downloadURL=$(curl -fs https://www.clevertouch.com/eu/clevershare2g | grep -i -o -E "https.*Mac.*\.dmg")
appNewVersion=$( echo "${downloadURL}" | sed -E 's/.*\/[a-zA-Z-]*_Mac\.([0-9.]*)\.[0-9]*\.dmg$/\1/g' )
printlog "Label for $name broken in test" ERROR
downloadURL=$(curl -fs https://www.clevertouch.com/eu/clevershare2g | grep -i -o -E "https.*notarized.*\.dmg")
appNewVersion=$(echo "${downloadURL}" | sed -E 's/.*\/([0-9.]*)\/[0-9]*\/.*\.dmg$/\1/')
expectedTeamID="P76M9BE8DQ"
;;

View File

@@ -0,0 +1,7 @@
cocoapods)
name="CocoaPods"
type="bz2"
downloadURL="$(downloadURLFromGit CocoaPods CocoaPods-app)"
appNewVersion="$(versionFromGit CocoaPods CocoaPods-app)"
expectedTeamID="AX2Q2BH2XR"
;;

View File

@@ -0,0 +1,7 @@
coconutbattery)
name="coconutBattery"
type="zip"
downloadURL="https://coconut-flavour.com/downloads/coconutBattery_latest.zip"
appNewVersion=$(curl -fs https://www.coconut-flavour.com/coconutbattery/ | grep "<title>" | sed -e 's/.*coconutBattery \(.*\) - by coconut-flavour.co.*/\1/')
expectedTeamID="R5SC3K86L5"
;;

View File

@@ -1,7 +1,7 @@
coderunner)
# credit: Erik Stam (@erikstam)
name="CodeRunner"
type="zip"
downloadURL="https://coderunnerapp.com/download"
appNewVersion=$(curl -fsIL ${downloadURL} | grep -i "^location" | cut -d " " -f2 | sed -E 's/.*CodeRunner-([0-9.]*).zip/\1/')
expectedTeamID="R4GD98AJF9"
;;

View File

@@ -1,5 +1,5 @@
colourcontrastanalyser)
name="Colour Contrast Analyser (CCA)"
name="Colour Contrast Analyser"
type="dmg"
downloadURL=$(downloadURLFromGit ThePacielloGroup CCAe)
appNewVersion=$(versionFromGit ThePacielloGroup CCAe)

View File

@@ -0,0 +1,7 @@
cricutdesignspace)
name="Cricut Design Space"
type="dmg"
appNewVersion=$(getJSONValue "$(curl -fsL https://s3-us-west-2.amazonaws.com/staticcontent.cricut.com/a/software/osx-native/latest.json)" "rolloutVersion")
downloadURL=$(getJSONValue $(curl -fsL "https://apis.cricut.com/desktopdownload/InstallerFile?shard=a&operatingSystem=osxnative&fileName=CricutDesignSpace-Install-v${appNewVersion}.dmg") "result")
expectedTeamID="25627ZFVT7"
;;

View File

@@ -1,6 +1,12 @@
cryptomator)
name="Cryptomator"
type="dmg"
if [[ $(arch) == "arm64" ]]; then
archiveName="Cryptomator-[0-9.]*-arm64.dmg"
elif [[ $(arch) == "i386" ]]; then
archiveName="Cryptomator-[0-9.]*.dmg"
fi
downloadURL=$(downloadURLFromGit cryptomator cryptomator)
appNewVersion=$(versionFromGit cryptomator cryptomator)
expectedTeamID="YZQJQUHA3L"

View File

@@ -0,0 +1,11 @@
cytoscape)
name="Cytoscape"
#appName="Cytoscape Installer.app"
type="dmg"
downloadURL="$(downloadURLFromGit cytoscape cytoscape)"
appNewVersion="$(versionFromGit cytoscape cytoscape)"
installerTool="Cytoscape Installer.app"
CLIInstaller="Cytoscape Installer.app/Contents/MacOS/JavaApplicationStub"
CLIArguments=(-q)
expectedTeamID="35LDCJ33QT"
;;

View File

@@ -1,7 +1,7 @@
dangerzone)
name="Dangerzone"
type="dmg"
downloadURL="$(downloadURLFromGit firstlookmedia dangerzone)"
appNewVersion="$(versionFromGit firstlookmedia dangerzone)"
downloadURL="$(downloadURLFromGit freedomofpress dangerzone)"
appNewVersion="$(versionFromGit freedomofpress dangerzone)"
expectedTeamID="N9B95FDWH4"
;;

View File

@@ -1,7 +1,7 @@
drawio)
name="draw.io"
type="dmg"
archiveName="draw.io-universal-[0-9.]*.dmg"
archiveName="draw.io-universal-[0-9.]*.dmg$"
downloadURL="$(downloadURLFromGit jgraph drawio-desktop)"
appNewVersion="$(versionFromGit jgraph drawio-desktop)"
expectedTeamID="UZEUFB4N53"

View File

@@ -2,9 +2,9 @@ duckduckgo)
name="DuckDuckGo"
type="dmg"
#downloadURL="https://staticcdn.duckduckgo.com/macos-desktop-browser/duckduckgo.dmg"
#downloadURL=$(curl -fs https://staticcdn.duckduckgo.com/macos-desktop-browser/appcast.xml | xpath '(//rss/channel/item/enclosure/@url)[last()]' 2>/dev/null | cut -d '"' -f2)
downloadURL=$(curl -fs https://staticcdn.duckduckgo.com/macos-desktop-browser/appcast.xml | xpath '(//rss/channel/item/enclosure/@url)[1]' 2>/dev/null | cut -d '"' -f2)
#appNewVersion=$(curl -fs https://staticcdn.duckduckgo.com/macos-desktop-browser/appcast.xml | xpath '(//rss/channel/item/enclosure/@sparkle:version)[last()]' 2>/dev/null | cut -d '"' -f2)
appNewVersion=$(curl -fs https://staticcdn.duckduckgo.com/macos-desktop-browser/appcast.xml | xpath '(//rss/channel/item/sparkle:shortVersionString)[1]' 2>/dev/null | cut -d ">" -f2 | cut -d "<" -f1)
downloadURL=$(curl -fs https://staticcdn.duckduckgo.com/macos-desktop-browser/appcast.xml | xpath '(//rss/channel/item/enclosure/@url)[last()]' 2>/dev/null | cut -d '"' -f2)
#downloadURL=$(curl -fs https://staticcdn.duckduckgo.com/macos-desktop-browser/appcast.xml | xpath '(//rss/channel/item/enclosure/@url)[1]' 2>/dev/null | cut -d '"' -f2)
appNewVersion=$(curl -fs https://staticcdn.duckduckgo.com/macos-desktop-browser/appcast.xml | xpath '(//rss/channel/item/enclosure/@sparkle:version)[last()]' 2>/dev/null | cut -d '"' -f2)
#appNewVersion=$(curl -fs https://staticcdn.duckduckgo.com/macos-desktop-browser/appcast.xml | xpath '(//rss/channel/item/sparkle:shortVersionString)[1]' 2>/dev/null | cut -d ">" -f2 | cut -d "<" -f1)
expectedTeamID="HKE973VLUW"
;;

View File

@@ -0,0 +1,9 @@
duodevicehealth)
name="Duo Device Health"
type="pkgInDmg"
downloadURL="https://dl.duosecurity.com/DuoDeviceHealth-latest.dmg"
appNewVersion=$(curl -fsLIXGET "https://dl.duosecurity.com/DuoDeviceHealth-latest.dmg" | grep -i "^content-disposition" | sed -e 's/.*filename\=\"DuoDeviceHealth\-\(.*\)\.dmg\".*/\1/')
appName="Duo Device Health.app"
expectedTeamID="FNN8Z5JMFP"
;;

View File

@@ -0,0 +1,7 @@
dynalist)
name="Dynalist"
type="dmg"
downloadURL="https://dynalist.io/standalone/download?file=Dynalist.dmg"
appNewVersion=""
expectedTeamID="6JSW4SJWN9"
;;

7
fragments/labels/fellow Normal file
View File

@@ -0,0 +1,7 @@
fellow)
name="Fellow"
type="dmg"
downloadURL="https://fellow.app/desktop/download/darwin/latest/"
appNewVersion="$(curl -fsIL "${downloadURL}" | grep -i ^location | sed 's/^.*[^0-9]\([0-9]*\.[0-9]*\.[0-9]*\).*$/\1/' | head -1)"
expectedTeamID="2NF46HY8D8"
;;

View File

@@ -0,0 +1,7 @@
fellow)
name="Fellow"
type="dmg"
downloadURL="https://cdn.fellow.app/desktop/1.3.11/darwin/stable/universal/Fellow-1.3.11-universal.dmg"
appNewVersion=""
expectedTeamID="2NF46HY8D8"
;;

View File

@@ -0,0 +1,8 @@
filemakerpro)
name="FileMaker Pro"
type="dmg"
versionKey="BuildVersion"
downloadURL=$(curl -fs https://www.filemaker.com/redirects/ss.txt | grep '\"PRO..MAC\"' | tail -1 | sed "s|.*url\":\"\(.*\)\".*|\\1|")
appNewVersion=$(curl -fs https://www.filemaker.com/redirects/ss.txt | grep '\"PRO..MAC\"' | tail -1 | sed "s|.*fmp_\(.*\).dmg.*|\\1|")
expectedTeamID="J6K4T76U7W"
;;

View File

@@ -0,0 +1,7 @@
flexoptixapp)
name="FLEXOPTIX App"
type="dmg"
downloadURL="https://flexbox.reconfigure.me/download/electron/mac/x64/current"
appNewVersion=$(curl -fsIL "${downloadURL}" | grep -i ^location | sed -E 's/.*-([0-9.]*)\.dmg/\1/g')
expectedTeamID="C5JETSFPHL"
;;

View File

@@ -0,0 +1,7 @@
fujifilmwebcam)
name="FUJIFILM X Webcam 2"
type="pkg"
downloadURL=$(curl -fs "https://fujifilm-x.com/en-us/support/download/software/x-webcam/" | grep "https.*pkg" | sed -E 's/.*(https:\/\/dl.fujifilm-x\.com\/support\/software\/.*\.pkg[^\<]).*/\1/g' | sed -e 's/^"//' -e 's/"$//')
appNewVersion=$( echo${downloadURL}| sed -E 's/.*XWebcamIns([0-9]*).*/\1/g' | sed -E 's/([0-9])([0-9]).*/\1\.\2/g')
expectedTeamID="34LRP8AV2M"
;;

View File

@@ -0,0 +1,7 @@
gfxcardstatus)
name="gfxCardStatus"
type="zip"
downloadURL="$(downloadURLFromGit codykrieger gfxCardStatus)"
appNewVersion="$(versionFromGit codykrieger gfxCardStatus)"
expectedTeamID="LF22FTQC25"
;;

View File

@@ -2,7 +2,11 @@ golang)
name="GoLang"
type="pkg"
packageID="org.golang.go"
downloadURL="https://go.dev$(curl -fs "https://go.dev/dl/" | grep -i "downloadBox" | grep "pkg" | tr '"' '\n' | grep "pkg")"
if [[ $(arch) == "arm64" ]]; then
downloadURL="https://go.dev$(curl -fs "https://go.dev/dl/" | grep -i "downloadBox" | grep "darwin-arm" | tr '"' '\n' | grep "pkg")"
elif [[ $(arch) == "i386" ]]; then
downloadURL="https://go.dev$(curl -fs "https://go.dev/dl/" | grep -i "downloadBox" | grep "darwin-amd" | tr '"' '\n' | grep "pkg")"
fi
appNewVersion="$( echo "${downloadURL}" | sed -E 's/.*\/(go[0-9.]*)\..*/\1/g' )" # Version includes letters "go" in the beginning
expectedTeamID="EQHXZ8M8AV"
blockingProcesses=( NONE )

View File

@@ -0,0 +1,7 @@
googleadseditor)
name="Google Ads Editor"
type="dmg"
downloadURL="https://dl.google.com/adwords_editor/google_ads_editor.dmg"
appNewVersion=""
expectedTeamID="EQHXZ8M8AV"
;;

View File

@@ -3,8 +3,13 @@ googledrivefilestream)
# credit: Isaac Ordonez, Mann consulting (@mannconsulting)
name="Google Drive File Stream"
type="pkgInDmg"
packageID="com.google.drivefs"
if [[ $(arch) == "arm64" ]]; then
packageID="com.google.drivefs.arm64"
elif [[ $(arch) == "i386" ]]; then
packageID="com.google.drivefs.x86_64"
fi
downloadURL="https://dl.google.com/drive-file-stream/GoogleDriveFileStream.dmg" # downloadURL="https://dl.google.com/drive-file-stream/GoogleDrive.dmg"
blockingProcesses=( "Google Docs" "Google Drive" "Google Sheets" "Google Slides" )
appName="Google Drive.app"
expectedTeamID="EQHXZ8M8AV"
;;

View File

@@ -2,9 +2,8 @@ grammarly)
name="Grammarly Desktop"
type="dmg"
packageID="com.grammarly.ProjectLlama"
downloadURL=$(curl -fsL "https://download-mac.grammarly.com/appcast.xml" | xpath '//rss/channel/item[1]/enclosure/@url' 2>/dev/null | cut -d '"' -f 2)
downloadURL="https://download-mac.grammarly.com/Grammarly.dmg"
expectedTeamID="W8F64X92K3"
appNewVersion=$(curl -is "https://download-mac.grammarly.com/appcast.xml" | grep sparkle:version | tr ',' '\n' | grep sparkle:version | cut -d '"' -f 4)
# appName="Grammarly Installer.app"
installerTool="Grammarly Installer.app"
CLIInstaller="Grammarly Installer.app/Contents/MacOS/Grammarly Desktop"

14
fragments/labels/horos.sh Normal file
View File

@@ -0,0 +1,14 @@
horos)
name="Horos"
type="dmg"
versionKey="CFBundleGetInfoString"
appNewVersion=$(curl -fs https://github.com/horosproject/horos/blob/horos/Horos/Info.plist | grep -A 4 "CFBundleGetInfoString" | tail -1 | sed -r 's/.*Horos v([^<]+).*/\1/' | sed 's/ //g')
if [[ $(arch) == "arm64" ]]; then
downloadURL="https://horosproject.org/horos-content/Horos"$appNewVersion"_Apple.dmg"
TeamID="8NDFEW7285"
elif [[ $(arch) == "i386" ]]; then
downloadURL="https://horosproject.org/horos-content/Horos"$appNewVersion".dmg"
TeamID="TPT6TVH8UY"
fi
expectedTeamID=$TeamID
;;

View File

@@ -1,8 +1,7 @@
icons)
# credit: Mischa van der Bent (@mischavdbent)
name="Icons"
type="zip"
downloadURL=$(downloadURLFromGit sap macOS-icon-generator )
appNewVersion=$(versionFromGit sap macOS-icon-generator )
downloadURL=$(downloadURLFromGit SAP macOS-icon-generator )
appNewVersion=$(versionFromGit SAP macOS-icon-generator )
expectedTeamID="7R5ZEU67FQ"
;;

View File

@@ -1,7 +1,9 @@
insomnia)
name="insomnia"
name="Insomnia"
type="dmg"
downloadURL=$(downloadURLFromGit kong insomnia)
appNewVersion=$(versionFromGit kong insomnia)
#downloadURL=$(downloadURLFromGit kong insomnia)
downloadURL=$(curl -fs "https://updates.insomnia.rest/downloads/mac/latest?app=com.insomnia.app&source=website" | grep -o "https.*\.dmg")
#appNewVersion=$(versionFromGit kong insomnia)
appNewVersion=$(echo "$downloadURL" | sed -E 's/.*\/Insomnia.Core.([0-9.]*)\.dmg/\1/')
expectedTeamID="FX44YY62GV"
;;

View File

@@ -0,0 +1,8 @@
ipswupdater)
name="IPSW Updater"
type="zip"
ipswupdaterVersions=$(curl -fs "https://ipsw.app/download/updates.php?current_version=0.9.16")
downloadURL=$(getJSONValue "$ipswupdaterVersions" "[0].url")
appNewVersion=$(getJSONValue "$ipswupdaterVersions" "[0].version")
expectedTeamID="YRW6NUGA63"
;;

14
fragments/labels/kap.sh Normal file
View File

@@ -0,0 +1,14 @@
kap)
# credit: Lance Stephens (@pythoninthegrass on MacAdmins Slack)
name="Kap"
type="dmg"
if [[ $(arch) = "i386" ]]; then
archiveName="${name}-[0-9.]*-x64.${type}"
downloadURL=$(downloadURLFromGit wulkano kap | grep -i x64)
else
archiveName="${name}-[0-9.]*-arm64.${type}"
downloadURL=$(downloadURLFromGit wulkano kap | grep -i arm64)
fi
appNewVersion=$(versionFromGit wulkano Kap)
expectedTeamID="2KEEHXF6R6"
;;

View File

@@ -0,0 +1,8 @@
keepingyouawake)
name="KeepingYouAwake"
type="zip"
downloadURL=$(downloadURLFromGit newmarcel KeepingYouAwake)
appNewVersion=$(versionFromGit newmarcel KeepingYouAwake)
expectedTeamID="5KESHV9W85"
blockingProcesses=( "KeepingYouAwake" )
;;

View File

@@ -1,7 +1,7 @@
knockknock)
name="KnockKnock"
type="zip"
downloadURL=$( curl -fs "https://objective-see.com/products/knockknock.html" | grep https | grep "$type" | head -1 | tr '"' "\n" | grep "^http" )
appNewVersion=$( echo "${downloadURL}" | sed -E 's/.*\/[a-zA-Z]*_([0-9.]*)\..*/\1/g' )
downloadURL="$(downloadURLFromGit objective-see KnockKnock)"
appNewVersion="$(versionFromGit objective-see KnockKnock)"
expectedTeamID="VBG97UB4TA"
;;

View File

@@ -0,0 +1,7 @@
latexit)
name="LaTeXiT"
type="dmg"
downloadURL="$(curl -fs "https://pierre.chachatelier.fr/latexit/downloads/latexit-sparkle-en.rss" | xpath '(//rss/channel/item/enclosure/@url)[last()]' 2>/dev/null | cut -d '"' -f 2)"
appNewVersion="$(curl -fs "https://pierre.chachatelier.fr/latexit/downloads/latexit-sparkle-en.rss" | xpath '(//rss/channel/item/enclosure/@sparkle:shortVersionString)[last()]' 2>/dev/null | cut -d '"' -f 2)"
expectedTeamID="7SFX84GNR7"
;;

View File

@@ -0,0 +1,7 @@
lcadvancedvpnclient)
name="LANCOM Advanced VPN Client"
type="pkgInDmg"
appNewVersion=$(curl -fs https://www.ncp-e.com/de/service/download-vpn-client/ | grep -m 1 "NCP Secure Entry macOS Client" -A 1 | grep -i Version | sed "s|.*Version \(.*\) Rev.*|\\1|")
downloadURL=$(appShortVersion=`sed 's/[^0-9]//g' <<< $appNewVersion` && echo https://ftp.lancom.de/LANCOM-Releases/LC-VPN-Client/LC-Advanced-VPN-Client-macOS-"${appShortVersion}"-Rel-x86-64.dmg)
expectedTeamID="LL3KBL2M3A"
;;

View File

@@ -13,7 +13,7 @@ macports)
archiveName="Catalina.pkg"
;;
*)
cleanupAndExit 1 "macOS 10.14 or earlier not supported by Installomator."
cleanupAndExit 98 "macOS 10.14 or earlier not supported by Installomator."
;;
esac
downloadURL=$(downloadURLFromGit macports macports-base)

6
fragments/labels/masv.sh Normal file
View File

@@ -0,0 +1,6 @@
masv)
name="MASV"
type="dmg"
downloadURL="https://dl.massive.io/MASV.dmg"
expectedTeamID="VHKX7RCAY7"
;;

View File

@@ -0,0 +1,7 @@
merlinproject)
name="Merlin Project"
type="zip"
downloadURL="https://www.projectwizards.net/downloads/MerlinProject.zip"
appNewVersion="$(curl -fs "https://www.projectwizards.net/de/support/release-notes" | grep Version | head -n 6 | tail -n 1 | sed 's/[^0-9.]*//g')"
expectedTeamID="9R6P9VZV27"
;;

View File

@@ -1,10 +0,0 @@
microsoftyammer)
name="Yammer"
type="dmg"
downloadURL="https://aka.ms/yammer_desktop_mac"
#appNewVersion=$(curl -fs https://macadmins.software/latest.xml | xpath '//latest/oldpackage[id="com.microsoft.yammer.standalone"]/cfbundleshortversionstring' 2>/dev/null | sed -E 's/<cfbundleshortversionstring>([0-9.]*)<.*/\1/')
appNewVersion=$(curl -fsIL "$downloadURL" | grep -i location: | sed -E 's/.*\/[a-zA-Z]*-([0-9.]*)\..*/\1/g')
expectedTeamID="UBF8T346G9"
#updateTool="/Library/Application Support/Microsoft/MAU2.0/Microsoft AutoUpdate.app/Contents/MacOS/msupdate --list; /Library/Application Support/Microsoft/MAU2.0/Microsoft AutoUpdate.app/Contents/MacOS/msupdate"
#updateToolArguments=( --install --apps ?????? )
;;

View File

@@ -0,0 +1,8 @@
mongodbcompass)
name="MongoDB Compass"
type="dmg"
archiveName="mongodb-compass-[0-9.]*-darwin-x64.dmg"
downloadURL="$(downloadURLFromGit mongodb-js compass)"
appNewVersion="$(versionFromGit mongodb-js compass)"
expectedTeamID="4XWMY46275"
;;

View File

@@ -0,0 +1,7 @@
netspot)
name="NetSpot"
type="dmg"
downloadURL="https://cdn.netspotapp.com/download/NetSpot.dmg"
appNewVersion=$(curl -fs "https://www.netspotapp.com/updates/netspot2-appcast.xml" | xpath '(//rss/channel/item/enclosure/@sparkle:version)' 2>/dev/null | cut -d '"' -f 2)
expectedTeamID="5QLDY8TU83"
;;

View File

@@ -1,8 +1,9 @@
nudge)
name="Nudge"
type="pkg"
archiveName="Nudge-[0-9.]*.pkg"
downloadURL=$(downloadURLFromGit macadmins Nudge )
appNewVersion=$(versionFromGit macadmins Nudge )
expectedTeamID="9GQZ7KUFR6"
archiveName="Nudge-[0-9.]*.pkg"
;;

View File

@@ -0,0 +1,10 @@
nudgesuite)
name="Nudge Suite"
appName="Nudge.app"
type="pkg"
archiveName="Nudge_Suite-[0-9.]*.pkg"
downloadURL=$(downloadURLFromGit macadmins Nudge )
appNewVersion=$(versionFromGit macadmins Nudge )
expectedTeamID="9GQZ7KUFR6"
blockingProcesses=( "Nudge" )
;;

View File

@@ -1,7 +1,12 @@
obs)
# credit: Gabe Marchan (gabemarchan.com - @darklink87)
name="OBS"
type="dmg"
downloadURL=$(curl -fs "https://obsproject.com/download" | awk -F '"' "/dmg/ {print \$10}")
if [[ $(arch) == "arm64" ]]; then
archiveName="obs-studio-[0-9.]*-macos-arm64.dmg"
elif [[ $(arch) == "i386" ]]; then
archiveName="obs-studio-[0-9.]*-macos-x86_64.dmg"
fi
downloadURL=$(downloadURLFromGit obsproject obs-studio )
appNewVersion=$(versionFromGit obsproject obs-studio )
expectedTeamID="2MMRE5MTB8"
;;

View File

@@ -1,8 +1,8 @@
opera)
name="Opera"
type="dmg"
downloadURL=$(curl -fsIL "$(curl -fs "$(curl -fsIL "https://download.opera.com/download/get/?partner=www&opsys=MacOS" | grep -i "^location" | cut -d " " -f2 | tail -1 | tr -d '\r')" | grep download.opera.com | grep -io "https.*yes" | sed 's/\&amp;/\&/g')" | grep -i "^location" | cut -d " " -f2 | tr -d '\r')
appNewVersion="$(curl -fs "https://get.geo.opera.com/ftp/pub/opera/desktop/" | grep "href=\"\d" | sort -V | tail -1 | tr '"' '\n' | grep "/" | head -1 | tr -d '/')"
downloadURL="$(curl -fsIL "$(curl -fs "$(curl -fsL "https://download.opera.com/download/get/?partner=www&opsys=MacOS" | tr '"' "\n" | grep -e "www.opera.com.*thanks.*opera" | sed 's/\&amp\;/\&/g')" | tr '"' "\n" | grep "download.opera.com" | sed 's/\&amp\;/\&/g')" | grep -i "^location" | grep -io "https.*dmg")"
appNewVersion="$(printf "$downloadURL" | sed -E 's/https.*\/([0-9.]*)\/mac\/.*/\1/')"
versionKey="CFBundleVersion"
expectedTeamID="A2P9LX4JPN"
;;

View File

@@ -0,0 +1,7 @@
origin)
name="Origin"
type="dmg"
downloadURL="https://www.dm.origin.com/mac/download/Origin.dmg"
expectedTeamID="TSTV75T6Q5"
blockingProcesses=( "Origin" )
;;

View File

@@ -0,0 +1,7 @@
parallelsrasclient)
name="Parallels Client"
type="pkg"
appNewVersion=$(curl -sf "https://download.parallels.com/ras/v18/RAS%20Client%20for%20Mac%20Changelog.txt" | grep -m 1 "Parallels Client for Mac Version" | sed "s|.*Version \(.*\) -.*|\\1|" | sed 's/ /./g' | sed 's/[^0-9.]//g')
downloadURL=$(appMajorVersion=`sed 's/\..*//' <<< $appNewVersion` && appHyphenVersion=`curl -sf "https://download.parallels.com/ras/v18/RAS%20Client%20for%20Mac%20Changelog.txt" | grep -m 1 "Parallels Client for Mac Version" | sed "s|.*Version \(.*\) -.*|\\1|" | sed 's/ /-/g' | sed 's/[^0-9.-]//g'` && echo https://download.parallels.com/ras/v"$appMajorVersion"/"$appNewVersion"/RasClient-Mac-Notarized-"$appHyphenVersion".pkg)
expectedTeamID="4C6364ACXT"
;;

View File

@@ -0,0 +1,7 @@
polylens)
name="Poly Lens"
type="dmg"
appNewVersion=$(curl -fs "https://info.lens.poly.com/lens-dt-rn/atom.xml" | grep "Version" | head -1 | cut -d "[" -f3 | sed 's/Version //g' | sed 's/]]\>\<\/title\>//g')
downloadURL="https://swupdate.lens.poly.com/lens-desktop-mac/$appNewVersion/$appNewVersion/PolyLens-$appNewVersion.dmg"
expectedTeamID="SKWK2Q7JJV"
;;

View File

@@ -0,0 +1,7 @@
prune)
name="Prune"
type="zip"
downloadURL=$(downloadURLFromGit BIG-RAT Prune)
appNewVersion=$(versionFromGit BIG-RAT Prune)
expectedTeamID="PS2F6S478M"
;;

View File

@@ -1,7 +1,12 @@
r)
name="R"
type="pkg"
downloadURL="https://cloud.r-project.org/bin/macosx/$( curl -fsL https://cloud.r-project.org/bin/macosx/ | grep -m 1 -o '<a href=".*pkg">' | sed -E 's/.+"(.+)".+/\1/g' )"
appNewVersion=$(echo "${downloadURL}" | sed -E 's/.*\/[a-zA-Z]*-([0-9.]*)\..*/\1/g')
if [[ $(arch) == "arm64" ]]; then
downloadURL="https://cloud.r-project.org/bin/macosx/$( curl -fsL https://cloud.r-project.org/bin/macosx/ | grep -m 1 -o '<a href=".*arm64\.pkg">' | sed -E 's/.+"(.+)".+/\1/g' )"
appNewVersion=$(echo "${downloadURL}" | sed -E 's/.*\/[a-zA-Z]*-([0-9.]*)-.*\..*/\1/g')
elif [[ $(arch) == "i386" ]]; then
downloadURL="https://cloud.r-project.org/bin/macosx/$( curl -fsL https://cloud.r-project.org/bin/macosx/ | grep -o '<a href=".*pkg">' | grep -m 1 -v "arm64" | sed -E 's/.+"(.+)".+/\1/g' )"
appNewVersion=$(echo "${downloadURL}" | sed -E 's/.*\/[a-zA-Z]*-([0-9.]*)\..*/\1/g')
fi
expectedTeamID="VZLD955F6P"
;;

View File

@@ -0,0 +1,7 @@
relatel)
name="Relatel"
type="dmg"
downloadURL="https://cdn.rela.tel/www/public/junotron/Relatel.dmg"
appNewVersion="$(curl -fs "https://cdn.firmafon.dk/www/public/junotron/latest-mac.yml" | grep -i "version" | cut -w -f2)"
expectedTeamID="B9358QF55B"
;;

View File

@@ -1,7 +0,0 @@
remotix)
name="Remotix"
type="dmg"
downloadURL="https://remotix.com/downloads/latest-remotix-mac/"
appNewVersion=$( curl -fsIL "${downloadURL}" | grep -i "^location" | sed -E 's/.*\/[a-zA-Z]*-([0-9.]*)-.*\.dmg/\1/g' )
expectedTeamID="K293Y6CVN4"
;;

View File

@@ -1,8 +0,0 @@
remotixagent)
name="RemotixAgent"
type="pkg"
packageID="com.nulana.rxagentmac"
downloadURL="https://remotix.com/downloads/latest-agent-mac/"
appNewVersion=$( curl -fsIL "${downloadURL}" | grep -i "^location" | sed -E 's/.*\/[a-zA-Z]*-([0-9.]*)-.*\.pkg/\1/g' )
expectedTeamID="K293Y6CVN4"
;;

View File

@@ -2,6 +2,6 @@ rstudio)
name="RStudio"
type="dmg"
downloadURL=$(curl -s -L "https://rstudio.com/products/rstudio/download/" | grep -m 1 -Eio 'href="https://download1.rstudio.org/desktop/macos/RStudio-(.*).dmg"' | cut -c7- | sed -e 's/"$//')
appNewVersion=$( echo "${downloadURL}" | sed -E 's/.*\/[a-zA-Z]*-([0-9.]*)\..*/\1/g' )
appNewVersion=$( echo "${downloadURL}" | sed -E 's/.*\/[a-zA-Z]*-([0-9.-]*)\..*/\1/g' | sed 's/-/+/' )
expectedTeamID="FYF2F5GFX4"
;;

View File

@@ -1,7 +1,12 @@
screamingfrogseospider)
name="Screaming Frog SEO Spider"
type="dmg"
downloadURL=$(curl -fs "https://www.screamingfrog.co.uk/wp-content/themes/screamingfrog/inc/download-modal.php" | grep -i -o "https.*\.dmg" | head -1)
if [[ $(arch) == i386 ]]; then
platform="Mac - (intel)"
elif [[ $(arch) == arm64 ]]; then
platform="Mac - (apple silicon)"
fi
downloadURL=$(curl -fs "https://www.screamingfrog.co.uk/wp-content/themes/screamingfrog/inc/download-modal.php" | grep "${platform}" | grep -i -o "https.*\.dmg" | head -1)
appNewVersion=$(print "$downloadURL" | sed -E 's/https.*\/[a-zA-Z]*-([0-9.]*)\.dmg/\1/g')".0"
expectedTeamID="CAHEVC3HZC"
;;

View File

@@ -0,0 +1,7 @@
sonicvisualiser)
name="Sonic Visualiser"
type="dmg"
downloadURL="$(downloadURLFromGit sonic-visualiser sonic-visualiser)"
appNewVersion="$(versionFromGit sonic-visualiser sonic-visualiser)"
expectedTeamID="73F996B92S"
;;

View File

@@ -0,0 +1,8 @@
splashtopbusiness)
name="Splashtop Business"
type="pkgInDmg"
splashtopbusinessVersions=$(curl -fsL "https://www.splashtop.com/wp-content/themes/responsive/downloadx.php?product=stb&platform=mac-client")
downloadURL=$(getJSONValue "$splashtopbusinessVersions" "url")
appNewVersion="${${downloadURL#*INSTALLER_v}%*.dmg}"
expectedTeamID="CPQQ3AW49Y"
;;

View File

@@ -0,0 +1,9 @@
strongdm)
name="strongDM"
type="dmg"
downloadURL="https://app.strongdm.com/downloads/client/darwin"
appNewVersion=$(curl -fsLIXGET "https://app.strongdm.com/downloads/client/darwin" | grep -i "^content-disposition" | sed -e 's/.*filename\=\"SDM\-\(.*\)\.dmg\".*/\1/')
appName="SDM.app"
blockingProcesses=( "SDM" )
expectedTeamID="W5HSYBBJGA"
;;

View File

@@ -2,7 +2,7 @@ sublimetext)
# credit: Søren Theilgaard (@theilgaard)
name="Sublime Text"
type="zip"
downloadURL="$(curl -fs https://www.sublimetext.com/download | grep -io "https://download.*_mac.zip")"
downloadURL="$(curl -fs "https://www.sublimetext.com/download_thanks?target=mac#direct-downloads" | grep -io "https://download.*_mac.zip" | head -1)"
appNewVersion=$(curl -fs https://www.sublimetext.com/download | grep -i -A 4 "id.*changelog" | grep -io "Build [0-9]*")
expectedTeamID="Z6D26JE4Y4"
;;

View File

@@ -5,6 +5,5 @@ supportapp)
downloadURL=$(downloadURLFromGit root3nl SupportApp)
appNewVersion=$(versionFromGit root3nl SupportApp)
expectedTeamID="98LJ4XBGYK"
uid=$(id -u "$currentUser")
launchctl bootout gui/${uid} "/Library/LaunchAgents/nl.root3.support.plist"
blockingProcesses=( NONE )
;;

View File

@@ -0,0 +1,8 @@
synologyassistant)
name="SynologyAssistant"
type="dmg"
packageID="com.synology.DSAssistant"
appNewVersion="$(curl -sf https://archive.synology.com/download/Utility/Assistant | grep -m 1 /download/Utility/Assistant/ | sed "s|.*>\(.*\)<.*|\\1|")"
downloadURL="https://global.download.synology.com/download/Utility/Assistant/${appNewVersion}/Mac/synology-assistant-${appNewVersion}.dmg"
expectedTeamID="X85BAK35Y4"
;;

View File

@@ -0,0 +1,8 @@
synologydriveclient)
name="Synology Drive Client"
type="pkgInDmg"
packageID="com.synology.CloudStation"
downloadURL=$(appVersion=`curl -sf https://archive.synology.com/download/Utility/SynologyDriveClient | grep -m 1 /download/Utility/SynologyDriveClient/ | sed "s|.*>\(.*\)<.*|\\1|"` && appShortVersion=`sed 's#.*-\(\)#\1#' <<< $appVersion` && echo https://global.download.synology.com/download/Utility/SynologyDriveClient/"$appVersion"/Mac/Installer/synology-drive-client-"${appShortVersion}".dmg)
appNewVersion=$(appVersionP1=`curl -sf https://archive.synology.com/download/Utility/SynologyDriveClient | grep -m 1 /download/Utility/SynologyDriveClient/ | sed "s|.*>\(.*\)-.*|\\1|"` && sed 's/\(.\{0\}\)./\17/' <<< $appVersionP1)
expectedTeamID="X85BAK35Y4"
;;

View File

@@ -0,0 +1,8 @@
tailscale)
name="Tailscale"
type="zip"
appNewVersion="$(curl -s https://pkgs.tailscale.com/stable/ | awk -F- '/Tailscale.*macos.zip/ {print $2}')"
downloadURL="https://pkgs.tailscale.com/stable/Tailscale-${appNewVersion}-macos.zip"
expectedTeamID="W5364U7YZB"
versionKey="CFBundleShortVersionString"
;;

View File

@@ -1,7 +1,8 @@
talkdeskcallbar)
name="Callbar"
type="dmg"
appNewVersion=$(curl -fsL https://downloadcallbar.talkdesk.com/release_metadata.json | sed -n 's/^.*"version"[[:space:]]*:[[:space:]]*"\([^"]*\)".*$/\1/p')
talkdeskcallbarVersions=$(curl -fsL "https://downloadcallbar.talkdesk.com/release_metadata.json")
appNewVersion=$(getJSONValue "$talkdeskcallbarVersions" "version")
downloadURL=https://downloadcallbar.talkdesk.com/Callbar-${appNewVersion}.dmg
expectedTeamID="YGGJX44TB8"
;;

View File

@@ -1,7 +1,8 @@
talkdeskcxcloud)
name="Talkdesk"
type="dmg"
appNewVersion=$(curl -fs https://td-infra-prd-us-east-1-s3-atlaselectron.s3.amazonaws.com/talkdesk-latest-metadata.json | sed -n -e 's/^.*"version"[[:space:]]*:[[:space:]]*"\([^"]*\)".*$/\1/p' | head -n 1)
talkdeskcxcloudVersions=$(curl -fs "https://td-infra-prd-us-east-1-s3-atlaselectron.s3.amazonaws.com/talkdesk-latest-metadata.json")
appNewVersion=$(getJSONValue "$talkdeskcxcloudVersions" "[0].version")
downloadURL="https://td-infra-prd-us-east-1-s3-atlaselectron.s3.amazonaws.com/talkdesk-${appNewVersion}.dmg"
expectedTeamID="YGGJX44TB8"
;;

View File

@@ -0,0 +1,15 @@
tencentmeeting)
name="TencentMeeting"
type="dmg"
if [[ $(arch) == "arm64" ]]; then
downloadURL="$(curl -fs 'https://meeting.tencent.com/web-service/query-download-info?q=%5B%7B%22package-type%22%3A%22app%22%2C%22channel%22%3A%220300000000%22%2C%22platform%22%3A%22mac%22%2C%22arch%22%3A%22arm64%22%7D%5D&c_os=web&c_os_version=1&c_os_model=web&c_timestamp=1653366550252&c_instance_id=5&c_nonce=DcaDam4y&c_app_id=1400143280&c_app_version=1&c_lang=zh-cn&c_district=0&nonce=miwSceJNQaSZttma' -H 'authority: meeting.tencent.com' -H 'referer: https://meeting.tencent.com/download-mac.html?from=1000&fromSource=1&macType=apple' -H 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/15.5 Safari/605.1.15' | grep -o "https://updatecdn.meeting.qq.com[^']*\.publish.arm64.dmg")"
appNewVersion=$(curl -fs 'https://meeting.tencent.com/web-service/query-download-info?q=%5B%7B%22package-type%22%3A%22app%22%2C%22channel%22%3A%220300000000%22%2C%22platform%22%3A%22mac%22%2C%22arch%22%3A%22arm64%22%7D%5D&c_os=web&c_os_version=1&c_os_model=web&c_timestamp=1653366550252&c_instance_id=5&c_nonce=DcaDam4y&c_app_id=1400143280&c_app_version=1&c_lang=zh-cn&c_district=0&nonce=miwSceJNQaSZttma' -H 'authority: meeting.tencent.com' -H 'referer: https://meeting.tencent.com/download-mac.html?from=1000&fromSource=1&macType=apple' -H 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/15.5 Safari/605.1.15' | grep -o "https://updatecdn.meeting.qq.com[^']*\.publish.arm64.dmg" | sed -e 's/.*TencentMeeting\_0300000000\_\(.*\)\.publish\.arm64\.dmg.*/\1/')
elif [[ $(arch) == "i386" ]]; then
downloadURL="$(curl -fs 'https://meeting.tencent.com/web-service/query-download-info?q=%5B%7B%22package-type%22%3A%22app%22%2C%22channel%22%3A%220300000000%22%2C%22platform%22%3A%22mac%22%2C%22arch%22%3A%22x86_64%22%7D%5D&c_os=web&c_os_version=1&c_os_model=web&c_timestamp=1653366500890&c_instance_id=5&c_nonce=jA4P4JPY&c_app_id=1400143280&c_app_version=1&c_lang=zh-cn&c_district=0&nonce=tF6Bm4FYHJwdPeGH' -H 'authority: meeting.tencent.com' -H 'referer: https://meeting.tencent.com/download-mac.html?from=1000&fromSource=1' -H 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/15.5 Safari/605.1.15' | grep -o "https://updatecdn.meeting.qq.com[^']*\.publish.x86_64.dmg")"
appNewVersion=$(curl -fs 'https://meeting.tencent.com/web-service/query-download-info?q=%5B%7B%22package-type%22%3A%22app%22%2C%22channel%22%3A%220300000000%22%2C%22platform%22%3A%22mac%22%2C%22arch%22%3A%22x86_64%22%7D%5D&c_os=web&c_os_version=1&c_os_model=web&c_timestamp=1653366500890&c_instance_id=5&c_nonce=jA4P4JPY&c_app_id=1400143280&c_app_version=1&c_lang=zh-cn&c_district=0&nonce=tF6Bm4FYHJwdPeGH' -H 'authority: meeting.tencent.com' -H 'referer: https://meeting.tencent.com/download-mac.html?from=1000&fromSource=1' -H 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/15.5 Safari/605.1.15' | grep -o "https://updatecdn.meeting.qq.com[^']*\.publish.x86_64.dmg" | sed -e 's/.*TencentMeeting\_0300000000\_\(.*\)\.publish\.x86_64\.dmg.*/\1/')
fi
curlOptions=( -H "User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/15.5 Safari/605.1.15" )
appCustomVersion() { echo "$(defaults read /Applications/TencentMeeting.app/Contents/Info.plist CFBundleShortVersionString)$(echo ".")$(defaults read /Applications/TencentMeeting.app/Contents/Info.plist CFBundleVersion)" }
expectedTeamID="88L2Q4487U"
;;

View File

@@ -0,0 +1,7 @@
typinator)
name="Typinator"
type="zip"
downloadURL=https://update.ergonis.com/downloads/products/typinator/Typinator.app.zip
appNewVersion="$(curl -fs https://update.ergonis.com/vck/typinator.xml | grep -i Program_Version | sed "s|.*>\(.*\)<.*|\\1|")"
expectedTeamID="TU7D9Y7GTQ"
;;

View File

@@ -3,10 +3,11 @@ vlc)
type="dmg"
if [[ $(arch) == "arm64" ]]; then
downloadURL=$(curl -fs http://update.videolan.org/vlc/sparkle/vlc-arm64.xml | xpath '//rss/channel/item[last()]/enclosure/@url' 2>/dev/null | cut -d '"' -f 2 )
appNewVersion=$(curl -fs http://update.videolan.org/vlc/sparkle/vlc-arm64.xml | xpath '//rss/channel/item[last()]/enclosure/@sparkle:version' 2>/dev/null | cut -d '"' -f 2 )
#appNewVersion=$(curl -fs http://update.videolan.org/vlc/sparkle/vlc-arm64.xml | xpath '//rss/channel/item[last()]/enclosure/@sparkle:version' 2>/dev/null | cut -d '"' -f 2 )
elif [[ $(arch) == "i386" ]]; then
downloadURL=$(curl -fs http://update.videolan.org/vlc/sparkle/vlc-intel64.xml | xpath '//rss/channel/item[last()]/enclosure/@url' 2>/dev/null | cut -d '"' -f 2 )
appNewVersion=$(curl -fs http://update.videolan.org/vlc/sparkle/vlc-intel64.xml | xpath '//rss/channel/item[last()]/enclosure/@sparkle:version' 2>/dev/null | cut -d '"' -f 2 )
#appNewVersion=$(curl -fs http://update.videolan.org/vlc/sparkle/vlc-intel64.xml | xpath '//rss/channel/item[last()]/enclosure/@sparkle:version' 2>/dev/null | cut -d '"' -f 2 )
fi
appNewVersion=$(echo ${downloadURL} | sed -E 's/.*\/vlc-([0-9.]*).*\.dmg/\1/' )
expectedTeamID="75GAHG3SZQ"
;;

View File

@@ -1,7 +1,8 @@
vmwarehorizonclient)
name="VMware Horizon Client"
type="dmg"
downloadURL=$(curl -fsL "https://my.vmware.com/channel/public/api/v1.0/dlg/details?locale=en_US&downloadGroup=CART21FQ2_MAC_800&productId=1027&rPId=48989" | grep -o 'Url.*..dmg"' | cut -d '"' -f3)
appNewVersion=$(curl -fsL "https://my.vmware.com/channel/public/api/v1.0/dlg/details?locale=en_US&downloadGroup=CART21FQ2_MAC_800&productId=1027&rPId=48989" | sed 's/.*-\(.*\)-.*/\1/')
expectedTeamID="EG7KH642X6"
downloadGroup=$(curl -fsL "https://my.vmware.com/channel/public/api/v1.0/products/getRelatedDLGList?locale=en_US&category=desktop_end_user_computing&product=vmware_horizon_clients&version=horizon_8&dlgType=PRODUCT_BINARY" | grep -o '[^"]*_MAC_[^"]*')
fileName=$(curl -fsL "https://my.vmware.com/channel/public/api/v1.0/dlg/details?locale=en_US&category=desktop_end_user_computing&product=vmware_horizon_clients&dlgType=PRODUCT_BINARY&downloadGroup=${downloadGroup}" | grep -o '"fileName":"[^"]*"' | cut -d: -f2 | sed 's/"//g')
downloadURL="https://download3.vmware.com/software/$downloadGroup/${fileName}"
appNewVersion=$(curl -fsL "https://my.vmware.com/channel/public/api/v1.0/dlg/details?locale=en_US&downloadGroup=${downloadGroup}" | grep -o '[^"]*\.dmg[^"]*' | sed 's/.*-\(.*\)-.*/\1/') expectedTeamID="EG7KH642X6"
;;

View File

@@ -1,11 +1,11 @@
wireshark)
name="Wireshark"
type="dmg"
if [[ $(arch) == i386 ]]; then
downloadURL="https://1.as.dl.wireshark.org/osx/Wireshark%20Latest%20Intel%2064.dmg"
elif [[ $(arch) == arm64 ]]; then
downloadURL="https://1.as.dl.wireshark.org/osx/Wireshark%20Latest%20Arm%2064.dmg"
fi
appNewVersion=$(curl -fs https://www.wireshark.org/download.html | grep -i "href.*_stable" | sed -E 's/.*\(([0-9.]*)\).*/\1/g')
if [[ $(arch) == i386 ]]; then
downloadURL="https://1.as.dl.wireshark.org/osx/Wireshark%20$appNewVersion%20Intel%2064.dmg"
elif [[ $(arch) == arm64 ]]; then
downloadURL="https://1.as.dl.wireshark.org/osx/Wireshark%20$appNewVersion%20Arm%2064.dmg"
fi
expectedTeamID="7Z6EMTD2C6"
;;

View File

@@ -0,0 +1,14 @@
xcreds)
name="XCreds"
# Downloading from twocanoes homepage
#type="pkgInDmg"
#packageID="com.twocanoes.pkg.secureremoteaccess"
#downloadURL=$(curl -fs "https://twocanoes.com/products/mac/xcreds/" | grep -ioE "https://.*\.zip" | head -1)
#appNewVersion=$(curl -fs "https://twocanoes.com/products/mac/xcreds/" | grep -io "Current Version:.*" | sed -E 's/.*XCreds *([0-9.]*)<.*/\1/g')
# GitHub download
type="pkg"
downloadURL="$(downloadURLFromGit twocanoes xcreds)"
#appNewVersion="$(versionFromGit twocanoes xcreds)" # GitHub tag contain “_” and not “.” so our function fails to get the right version
appNewVersion=$(echo "$downloadURL" | sed -E 's/.*XCreds_.*-([0-9.]*)\.pkg/\1/')
expectedTeamID="UXP6YEHSPW"
;;

View File

@@ -0,0 +1,10 @@
zoomoutlookplugin)
name="Zoom Outlook Plugin"
appName="PluginLauncher.app"
targetDir="/Applications/ZoomOutlookPlugin"
type="pkg"
downloadURL="https://zoom.us/client/latest/ZoomMacOutlookPlugin.pkg"
appNewVersion="$(curl -fsIL ${downloadURL} | grep -i ^location | cut -d "/" -f5 | cut -d "." -f1-3)"
expectedTeamID="BJ4HAAB9B3"
blockingProcesses=( "PluginLauncher" )
;;

View File

@@ -0,0 +1,8 @@
zotero)
name="Zotero"
type="dmg"
downloadURL="https://www.zotero.org/download/client/dl?channel=release&platform=mac&version=$(curl -fs "https://www.zotero.org/download/" | grep -Eio '"mac":"(.*)' | cut -d '"' -f 4)"
expectedTeamID="8LAYR367YV"
appNewVersion=$(curl -fs "https://www.zotero.org/download/" | grep -Eio '"mac":"(.*)' | cut -d '"' -f 4)
#Company="Corporation for Digital Scholarship"
;;

View File

@@ -15,10 +15,33 @@ fi
# MARK: application download and installation starts here
# Debug output of all variables in a label
printlog "name=${name}" DEBUG
printlog "appName=${appName}" DEBUG
printlog "type=${type}" DEBUG
printlog "archiveName=${archiveName}" DEBUG
printlog "downloadURL=${downloadURL}" DEBUG
printlog "curlOptions=${curlOptions}" DEBUG
printlog "appNewVersion=${appNewVersion}" DEBUG
printlog "appCustomVersion function: $(if type 'appCustomVersion' 2>/dev/null | grep -q 'function'; then echo "Defined. ${appCustomVersion}"; else; echo "Not defined"; fi)" DEBUG
printlog "versionKey=${versionKey}" DEBUG
printlog "packageID=${packageID}" DEBUG
printlog "pkgName=${pkgName}" DEBUG
printlog "choiceChangesXML=${choiceChangesXML}" DEBUG
printlog "expectedTeamID=${expectedTeamID}" DEBUG
printlog "blockingProcesses=${blockingProcesses}" DEBUG
printlog "installerTool=${installerTool}" DEBUG
printlog "CLIInstaller=${CLIInstaller}" DEBUG
printlog "CLIArguments=${CLIArguments}" DEBUG
printlog "updateTool=${updateTool}" DEBUG
printlog "updateToolArguments=${updateToolArguments}" DEBUG
printlog "updateToolRunAsCurrentUser=${updateToolRunAsCurrentUser}" DEBUG
#printlog "Company=${Company}" DEBUG # Not used
if [[ ${INTERRUPT_DND} = "no" ]]; then
# Check if a fullscreen app is active
if hasDisplaySleepAssertion; then
cleanupAndExit 1 "active display sleep assertion detected, aborting" ERROR
cleanupAndExit 24 "active display sleep assertion detected, aborting" ERROR
fi
fi
@@ -60,6 +83,11 @@ case $LOGO in
LOGO="/Library/Intune/Microsoft Intune Agent.app/Contents/Resources/AppIcon.icns"
if [[ -z $MDMProfileName ]]; then; MDMProfileName="Management Profile"; fi
;;
ws1)
# Workspace ONE (AirWatch)
LOGO="/Applications/Workspace ONE Intelligent Hub.app/Contents/Resources/AppIcon.icns"
if [[ -z $MDMProfileName ]]; then; MDMProfileName="Device Manager"; fi
;;
esac
if [[ ! -a "${LOGO}" ]]; then
if [[ $(sw_vers -buildVersion) > "19" ]]; then
@@ -75,7 +103,7 @@ printlog "Label type: $type" INFO
# MARK: extract info from data
if [ -z "$archiveName" ]; then
case $type in
dmg|pkg|zip|tbz)
dmg|pkg|zip|tbz|bz2)
archiveName="${name}.$type"
;;
pkgInDmg)
@@ -101,7 +129,7 @@ fi
if [ -z "$targetDir" ]; then
case $type in
dmg|zip|tbz|app*)
dmg|zip|tbz|bz2|app*)
targetDir="/Applications"
;;
pkg*)
@@ -132,7 +160,7 @@ fi
# MARK: change directory to temporary working directory
printlog "Changing directory to $tmpDir" DEBUG
if ! cd "$tmpDir"; then
cleanupAndExit 1 "error changing directory $tmpDir" ERROR
cleanupAndExit 13 "error changing directory $tmpDir" ERROR
fi
# MARK: get installed version
@@ -155,6 +183,10 @@ if [[ -n $appNewVersion ]]; then
printlog "notifying"
displaynotification "$message" "No update for $name!"
fi
if [[ $DIALOG_CMD_FILE != "" ]]; then
updateDialog "complete" "Latest version already installed..."
sleep 2
fi
cleanupAndExit 0 "No newer version." REQ
fi
else
@@ -168,6 +200,8 @@ fi
# MARK: check if this is an Update and we can use updateTool
if [[ (-n $appversion && -n "$updateTool") || "$type" == "updateronly" ]]; then
printlog "appversion & updateTool"
updateDialog "wait" "Updating..."
if [[ $DEBUG -ne 1 ]]; then
if runUpdateTool; then
finishing
@@ -194,8 +228,28 @@ else
displaynotification "Downloading new $name" "Download in progress …"
fi
fi
curlDownload=$(curl -v -fsL --show-error ${curlOptions} "$downloadURL" -o "$archiveName" 2>&1)
curlDownloadStatus=$(echo $?)
if [[ $DIALOG_CMD_FILE != "" ]]; then
# pipe
pipe="$tmpDir/downloadpipe"
# initialise named pipe for curl output
initNamedPipe create $pipe
# run the pipe read in the background
readDownloadPipe $pipe "$DIALOG_CMD_FILE" & downloadPipePID=$!
printlog "listening to output of curl with pipe $pipe and command file $DIALOG_CMD_FILE on PID $downloadPipePID" DEBUG
curlDownload=$(curl -fL -# --show-error ${curlOptions} "$downloadURL" -o "$archiveName" 2>&1 | tee $pipe)
# because we are tee-ing the output, we want the pipe status of the first command in the chain, not the most recent one
curlDownloadStatus=$(echo $pipestatus[1])
killProcess $downloadPipePID
else
printlog "No Dialog connection, just download" DEBUG
curlDownload=$(curl -v -fsL --show-error ${curlOptions} "$downloadURL" -o "$archiveName" 2>&1)
curlDownloadStatus=$(echo $?)
fi
deduplicatelogs "$curlDownload"
if [[ $curlDownloadStatus -ne 0 ]]; then
#if ! curl --location --fail --silent "$downloadURL" -o "$archiveName"; then
@@ -237,8 +291,10 @@ if [[ $currentUser != "loginwindow" && $NOTIFY == "all" ]]; then
printlog "notifying"
if [[ $updateDetected == "YES" ]]; then
displaynotification "Updating $name" "Installation in progress …"
updateDialog "wait" "Updating..."
else
displaynotification "Installing $name" "Installation in progress …"
updateDialog "wait" "Installing..."
fi
fi
@@ -258,7 +314,7 @@ case $type in
zip)
installFromZIP
;;
tbz)
tbz|bz2)
installFromTBZ
;;
pkgInDmg)
@@ -275,6 +331,8 @@ case $type in
;;
esac
updateDialog "wait" "Finishing..."
# MARK: Finishing — print installed application location and version
finishing

View File

@@ -1 +1 @@
10.0beta
10.0beta3