Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

added pending update list and Apple Silicon support #49

Merged
merged 8 commits into from
Mar 10, 2021

Conversation

mpanighetti
Copy link
Owner

@mpanighetti mpanighetti commented Dec 14, 2020

  • added comma-separated list of pending software updates to display in user-facing dialog boxes
  • added basic Apple Silicon architecture support Apple Silicon Macs require user interaction to run softwareupdate --install #45
    • script prompts for manual update action, opens System Preferences - Software Update, and repeats until no recommended updates are detected or the system is restarted
  • moved check_for_updates run before FORCE_DATE check (prevents the deferral countdown clock from starting until after update cache has finished on first script run)
  • switched default logo path to use /System/Library/PreferencePanes/SoftwareUpdate.prefPane/Contents/Resources/SoftwareUpdate.icns (Big Sur does not have an icon for the Software Update app)

- switched default logo path to use `/System/Library/PreferencePanes/SoftwareUpdate.prefPane/Contents/Resources/SoftwareUpdate.icns` (Big Sur does not have an icon for the Software Update app)
- moved `check_for_updates` run before `FORCE_DATE` check (prevents the deferral countdown clock from starting until after update cache has finished on first script run)
mpanighetti and others added 2 commits December 17, 2020 11:13
- added software update itemization (comma-separated list of updates and versions)
- updated default message text to accommodate update list
@mpanighetti mpanighetti changed the title switched default logo path added pending update list Dec 17, 2020
- reworded messaging to be more consistent with how it's framed around the update list, and generally rephrased "critical" to "recommended" to match softwareupdate output syntax
- iterated package version to match script version
- better comments
- made script display `MSG_ACT_NOW` alert and launch System Preferences - Software Update on repeat for manual updating on Apple Silicon Macs (update action is manual since scripting `softwareupdate --list` is currently unsupported on arm64)
- set update caching to only run on Intel Macs
- removed Apple Silicon bailout
- rewording of alerts and documentation to indicate potentially softer action at end of deferral period
@mpanighetti mpanighetti changed the title added pending update list added pending update list and Apple Silicon support Mar 9, 2021

# Loop this check until softwareupdate --list shows no more pending
# recommended updates.
while [[ $(/usr/sbin/softwareupdate --list) == *"Recommended: YES"* ]]; do
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Open to discussion on possibly adding a delay to this while loop. Maybe a sleep 60 before killall jamfHelper? Gives people a chance to save documents and quit apps before System Preferences reasserts itself.

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added sleep 60 below.

- updated version to 4.1 (changes constitute substantial new functionality or improvements while not impacting backward-compatibility as defined in SemVer specs)
- added sleep 60 to while loop (reduces frequency of alert resets)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants