Skip to content

macOS Shortcuts Workflows

Integrate Crona with macOS Shortcuts for TUI launchers, fast context switching, and automated exports.

On macOS, you can use the native Shortcuts app to execute Crona CLI commands, linking them to global hotkeys, menu bar items, or automated triggers.

Every workflow below utilizes the same Shortcuts action sequence:

  1. Open the macOS Shortcuts app and create a new Shortcut.
  2. Add a Run Shell Script action.
  3. Configure the shell (e.g., /bin/zsh or /bin/bash).
  4. Ensure the crona binary is accessible on the script’s PATH. If needed, prepend the path override:
    Terminal window
    export PATH="$HOME/.local/bin:$PATH"
    crona <command>

Create quick launchers that switch repositories or streams and then open the TUI immediately:

Terminal window
export PATH="$HOME/.local/bin:$PATH"
crona context switch-repo --id 1 --json
# Launches the TUI in the terminal
open -a Terminal "$(which crona)"
Terminal window
export PATH="$HOME/.local/bin:$PATH"
crona context switch-stream --id 3 --json
open -a Terminal "$(which crona)"

Workflow 2: Hotkey-Triggered Focus Sessions

Section titled “Workflow 2: Hotkey-Triggered Focus Sessions”

Set up global keyboard shortcuts to start or stop focus timers on the currently checked-out issue:

Terminal window
export PATH="$HOME/.local/bin:$PATH"
crona timer start --from-context --json

Create a Shortcut that prompts for input (the commit message), then ends the session:

Terminal window
export PATH="$HOME/.local/bin:$PATH"
# Reads the text input from the previous Shortcut action
crona timer end --message "$1" --json

Create an automated calendar sync Shortcut that exports your records and triggers a folder action:

Terminal window
export PATH="$HOME/.local/bin:$PATH"
crona export calendar --json

Pin this Shortcut to run hourly via a launchd daemon, or trigger it automatically when opening your email client.