fix: strip deprecated taps from Brewfile; restore Control Centre + menu bar
lib/brew.sh: Define _SSR_DEPRECATED_TAPS list (homebrew/core, /cask, /services, /test-bot, /bundle, /cask-fonts, /cask-drivers, /cask-versions). _ssr_brew_strip_deprecated_taps removes matching 'tap "…"' lines after dump so they never cause "Tapping X has failed!" errors on restore. lib/macos-prefs.sh: Add com.apple.controlcenter, com.apple.systemuiserver and com.apple.notificationcenterui to SSR_MACOS_PREF_DOMAINS_DEFAULT so Control Centre module toggles, menu-bar extras order and Notification Centre widgets are included in the pref snapshot on every sync. Also add ControlCenter to the post-import service restart list. lib/macos.sh: Add ControlCenter to ssr::macos::restart_ui so the menu bar and Control Centre panel pick up restored prefs immediately after mackup. Kill cfprefsd first in all restart sequences to flush the pref cache. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
+6
-2
@@ -19,6 +19,9 @@ SSR_MACOS_PREF_DOMAINS_DEFAULT=(
|
||||
com.apple.HIToolbox # input sources / keyboard layout
|
||||
com.apple.spaces # Spaces / Mission Control layout
|
||||
com.apple.menuextra.clock # menu-bar clock format
|
||||
com.apple.controlcenter # Control Centre module toggles (Wi-Fi, BT, Focus…)
|
||||
com.apple.systemuiserver # menu-bar extras order and extras list
|
||||
com.apple.notificationcenterui # Notification Centre widget layout
|
||||
NSGlobalDomain # a.k.a. .GlobalPreferences (UI/keyboard-repeat/sound…)
|
||||
)
|
||||
|
||||
@@ -223,9 +226,10 @@ ssr::macos::prefs_import() {
|
||||
ssr::ok "Imported $imported macOS pref domain(s)${skipped:+ ($skipped skipped)}."
|
||||
|
||||
# Restart affected services once so changes take effect.
|
||||
# cfprefsd first so the fresh plists are visible to other processes.
|
||||
local svc
|
||||
for svc in Dock Finder SystemUIServer cfprefsd; do
|
||||
for svc in cfprefsd Dock Finder SystemUIServer ControlCenter; do
|
||||
killall "$svc" 2>/dev/null || true
|
||||
done
|
||||
ssr::ok "Restarted Dock, Finder, SystemUIServer, cfprefsd."
|
||||
ssr::ok "Restarted Dock, Finder, SystemUIServer, ControlCenter, cfprefsd."
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user