Skip to content

Commit

Permalink
Better UI around Apple updates that don't require a restart on Apple …
Browse files Browse the repository at this point in the history
…silicon
  • Loading branch information
gregneagle committed May 24, 2022
1 parent 450294b commit f6c618a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -1215,6 +1215,10 @@ func update_list_sort(_ lh: UpdateItem, _ rh: UpdateItem) -> Bool {
func _build_update_list(_ filterAppleUpdates: Bool = false) -> [UpdateItem] {
var update_items = [[String: Any]]()
if !munkiUpdatesContainAppleItems() {
// don't show any Apple updates if there are Munki items that are Apple items
} else if (filterAppleUpdates && isAppleSilicon()) {
// we can't install any Apple updates on Apple silicon, so filter them all
} else {
for var item in getAppleUpdates() {
if (filterAppleUpdates &&
((item["RestartAction"] as? String ?? "").hasSuffix("Restart"))) {
Expand Down
3 changes: 2 additions & 1 deletion code/client/munkilib/appleupdates/au.py
Original file line number Diff line number Diff line change
Expand Up @@ -443,7 +443,8 @@ def get_apple_updates(self):
su_info['RestartAction'] = 'RequireRestart'
apple_updates.append(su_info)
continue
elif not self.update_downloaded(product_key):
elif not info.is_apple_silicon() and not self.update_downloaded(product_key):
# only check for downloaded if Intel
display.display_warning(
'Product %s does not appear to be downloaded',
product_key)
Expand Down

0 comments on commit f6c618a

Please sign in to comment.