1

I'm toggling a Mission Control setting with defaults write but the Dock doesn't see the change without restarting via killall Dock. How can I get the Dock to read the updated plist settings without killing it?

The setting is stored in the com.apple.dock plist, this is the command to update it (toggling the boolean):

defaults write com.apple.dock expose-group-apps -bool FALSE

Ideally, I want to use this command to quickly change the setting so I can use both window grouping modes with Mission Control, but restarting the dock is slow and disruptive, usually expanding any application windows minimized into the Dock. Is there some sort of notification/ping I can use to alert the Dock to its new settings?

1

Send the Dock process a signal called the 'hang-up' or HUP, also known as signal number 1 as defined somewhere in a system signals.h header file. POSIX convention, I believe.

The quick and dirty:

sudo pkill -1 Dock

What a HUP signal should effectuate in the receiving process is an internal halt and re-evaluation, which usually includes a re-reading of any relevant config files. The process will not terminate, only 'refresh' itself.

Hope this helps.

F.

| improve this answer | |
0

In a word, no.

The only way to get the Dock to re-read its preference plist is to kill it and wait for it to respawn.

| improve this answer | |

You must log in to answer this question.

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