A small macOS command-line utility for keeping the Dock focused on currently running apps.
It can:
- Show only currently running apps
- Hide suggested and recent apps
- Lock the Dock to prevent adding, removing, or rearranging items
- Save and restore your previous Dock settings
- macOS
- Zsh (included with modern macOS releases)
Clone the repository and run the script directly:
git clone https://github.com/ben-million/dock-mode.git
cd dock-mode
./dock-mode.sh enableAvailable commands:
enable Show only running apps, hide recent apps, and lock the Dock
disable Restore the settings saved by enable
running-only Show only currently running apps
normal Show pinned apps normally again
recents-off Hide suggested and recent apps
recents-on Show suggested and recent apps
lock Prevent adding, removing, or rearranging Dock items
unlock Allow Dock items to be changed
status Display the current settings
help Display help
Enable the complete running-apps-only setup:
./dock-mode.sh enableRestore the settings that were active before enable was first run:
./dock-mode.sh disableCheck the current state:
./dock-mode.sh statusThe Dock restarts briefly whenever a setting is changed. Finder, Trash, and other required system items may remain visible.
Dock Mode uses macOS defaults preferences. Some of these preferences are undocumented and could change in a future macOS release. No administrator privileges are required.