Skip to content

Scripting

Every hotkey step is also a shell command, so anything a binding does, a script, a launcher or another hotkey daemon can do too. Each neru command prints its reply, writes errors to stderr, and exits non-zero on failure. Commands are in the CLI reference, and the neru status --json fields under neru status.

Terminal window
if [ "$(neru status --json | jq -r .enabled)" = true ]; then neru stop; else neru start; fi
Terminal window
neru status &>/dev/null && echo "Running" || echo "Not running"
~/.config/skhd/skhdrc
ctrl - f : neru hints
ctrl - g : neru grid
ctrl - r : neru hints --action right_click

Use neru run instead of chaining neru calls with &&. It sends the whole sequence in one request, under hotkey binding rules.

To leave every global hotkey to the other daemon, see Recipes.

To skip the neru binary, send JSON over the socket. The format is in IPC protocol.