DockLock Plus CLI

Oct 13, 2025

DockLock Plus CLI Manual

Requires DockLock Plus v2.0.6 or newer.

Control DockLock Plus from the terminal or scripts. Use it to get or set mode, move the Dock, allow/disallow displays, query status, launch/quit the service, and more.


Usage

/Applications/DockLock\ Plus.app/Contents/MacOS/DockLock\ Plus [--help] [--version] <command> [<args>]

The DockLock Plus CLI must be invoked using the full path shown above, as it is embedded within the application bundle.

Global options:

  • -h, --help — show help
  • --version — print version

If no command is given, help is shown.


Commands

Command Purpose Usage / Arguments Notes / Return Values
mode Get or set Dock Control mode docklock mode
docklock mode <token>
Without args: returns current mode token.
With token: sets mode.
Valid tokens: lock-selected, follows-mouse,
follows-apps, follows-window, disabled
move Move the Dock `docklock move left right
allow Allow or disallow Dock on a display `docklock allow –display “” on off<br>docklock allow –xy on
displays List all displays docklock displays [--json] Returns display names
or JSON list with geometries,
dock visibility, and movable flag
display Show current display docklock display [--json] Prints current display name
or JSON struct with name and geometry
status Show DockLock status docklock status [--json] Prints mode, display, and dock state (hidden or visible)
launch Launch DockLock service docklock launch Starts the DockLock process if not already running
quit Quit DockLock service docklock quit Requests the DockLock service to terminate

Mode Tokens

When setting mode via docklock mode <token>, use one of:

Token Meaning
lock-selected Lock to selected displays
follows-mouse Follow mouse cursor
follows-apps Follow active apps
follows-window Follow active window
disabled Disable DockLock control

Examples

docklock mode
docklock mode follows-mouse
docklock move right
docklock move "Display 2"
docklock move 1920 0
docklock allow --display "Display 3" off
docklock allow --xy 500 300 on
docklock displays
docklock displays --json
docklock display
docklock status
docklock status --json
docklock launch
docklock quit

Output Formats & Exit Codes

  • Default output: plain text
  • With --json: structured JSON
  • Exit codes:
    • 0 — success
    • 1 — invalid usage
    • 2 — command-specific failure
    • >2 — internal/communication errors

URL Scheme

Send commands via custom docklockplus:// URLs to control DockLock Plus from scripts, browsers, or third‑party apps.
Learn how →

Apple Shortcuts

Create Shortcuts workflows on macOS to invoke DockLock Plus intents, assign hotkeys, or trigger via Siri.
Learn how →


Homepage | FAQ | Support