From a99cbc2c65b5e4bed73e20ee09d3103b738d3b0e Mon Sep 17 00:00:00 2001 From: Kevin <86124561+Macjutsu@users.noreply.github.com> Date: Fri, 20 May 2022 12:05:41 -0400 Subject: [PATCH] 1.1 --- CHANGELOG.md | 7 +++++++ super | 22 ++++++++++++++++++---- 2 files changed, 25 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 98d6f12..7265cd3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,12 @@ # CHANGELOG +## [1.1] + +2022-05-20 + +- Resolved missing code that prevented the `PreferJamf` managed preference key from being respected. +- The `--prefer-jamf` option will now result in an exit error if run from a computer with no Jamf binary. + ## [1.1b2] 2022-05-16 diff --git a/super b/super index 070253d..bfdb67e 100755 --- a/super +++ b/super @@ -6,8 +6,8 @@ # S.U.P.E.R.M.A.N. optimizes the macOS software update experience. # by Kevin M. White # -# Version 1.1b2 -# 2022/05/16 +# Version 1.1 +# 2022/05/20 # https://github.com/Macjutsu/super # ######## DEBUGGING STUFF ######## @@ -26,8 +26,8 @@ echo " S.U.P.E.R.M.A.N. Software Update Policy Enforcement (with) Recursive Messaging And Notification - Version 1.1b2 - 2022/05/16 + Version 1.1 + 2022/05/20 https://github.com/Macjutsu/super Usage: @@ -973,6 +973,20 @@ elif [[ -n $iconSizeJamfOPTION ]] && ! [[ $iconSizeJamfOPTION =~ $regexNUMBER ]] sendToLog "Exit: The Ibm Notifier icon size must only be a number."; parameterERROR="TRUE" fi +# Manage $preferJamfOPTION and save to $superPLIST. +if [[ -n $preferJamfOPTION ]]; then + if [[ $preferJamfOPTION -eq 1 ]] || [[ "$preferJamfOPTION" == "TRUE" ]]; then + if [[ "$jamfVERSION" != "FALSE" ]]; then + preferJamfOPTION="TRUE" + else + sendToLog "Exit: No local Jamf binary detected, thus can not prefer jamfHelper."; parameterERROR="TRUE" + fi + else + preferJamfOPTION="FALSE" + fi + defaults write "$superPLIST" PreferJamf -bool "$preferJamfOPTION" +fi + # Validate $focusDeadlineOPTION, if valid set $focusDEADLINE, $focusEPOCH, $focusDATE, $focusTIME, $focusDEADLINE, and $focusDISPLAY. if [[ "$focusDeadlineOPTION" == "X" ]]; then sendToLog "Starter: Deleting local preference for Focus deadline."