4

I need to run killall Dock in a script I use regularly, in order for it to work.

Unfortunately all the badges in the Dock disappears when Dock is killed, and don't reappear until they're modified individually by the the application in question. So if the Mail application for example has 123 unread emails as the badge, the badge disappears until I read an email or receive a new one.

How can I restore the badges for all apps at the same time though, in my script?

1
  • 1
    Having the same issue. Would love to find a solution.
    – HaggleLad
    Feb 4, 2021 at 19:54

1 Answer 1

1

In order to restore the badges, you need to add this command to your shell script:

defaults write com.apple.systempreferences AttentionPrefBundleIDs 1

...and then tell your script to kill Dock, so the next Dock instance is loaded with the new setting:

killall Dock
1
  • 1
    Appreciate the suggestion, but I just tried this and it didn't work, the badges were missing when the dock restarted :weep:
    – HaggleLad
    Aug 25, 2021 at 7:36

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .