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.
General Shortcut Setup
Section titled “General Shortcut Setup”Every workflow below utilizes the same Shortcuts action sequence:
- Open the macOS Shortcuts app and create a new Shortcut.
- Add a Run Shell Script action.
- Configure the shell (e.g.,
/bin/zshor/bin/bash). - Ensure the
cronabinary is accessible on the script’sPATH. If needed, prepend the path override:Terminal window export PATH="$HOME/.local/bin:$PATH"crona <command>
Workflow 1: Quick Workspace Launchers
Section titled “Workflow 1: Quick Workspace Launchers”Create quick launchers that switch repositories or streams and then open the TUI immediately:
Open Work Repository
Section titled “Open Work Repository”export PATH="$HOME/.local/bin:$PATH"crona context switch-repo --id 1 --json# Launches the TUI in the terminalopen -a Terminal "$(which crona)"Open Personal Stream
Section titled “Open Personal Stream”export PATH="$HOME/.local/bin:$PATH"crona context switch-stream --id 3 --jsonopen -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:
Start Active Focus
Section titled “Start Active Focus”export PATH="$HOME/.local/bin:$PATH"crona timer start --from-context --jsonStop Focus and Log Session
Section titled “Stop Focus and Log Session”Create a Shortcut that prompts for input (the commit message), then ends the session:
export PATH="$HOME/.local/bin:$PATH"# Reads the text input from the previous Shortcut actioncrona timer end --message "$1" --jsonWorkflow 3: Automated iCalendar Updates
Section titled “Workflow 3: Automated iCalendar Updates”Create an automated calendar sync Shortcut that exports your records and triggers a folder action:
export PATH="$HOME/.local/bin:$PATH"crona export calendar --jsonPin this Shortcut to run hourly via a launchd daemon, or trigger it automatically when opening your email client.