All pages
Docs · Start here
Custom shortcuts
Availability: macOS.
Custom shortcuts let you bind a keyboard chord to a TRMNLY action — running a saved prompt, running a runbook, sending text to the terminal, capturing a screenshot, or popping the prompt menu. They're different from Keybinds, which rebind Ghostty's built-in actions (new tab, copy, split…) through the config. Custom shortcuts add brand-new chord → action mappings that are dispatched in TRMNLY itself, so they can do things the terminal engine has no command for.
Manage them in Settings → Shortcuts.
What a shortcut can do
| Action | Does |
|---|---|
| Send Text | Inject literal text into the focused pane. Toggle Press Return after to run it immediately instead of leaving it at the prompt. |
| Run Saved Prompt | Fire one of your saved Prompts at the agent (with its variables expanded). |
| Run Runbook | Start a runbook in a fresh agent session. |
| Screenshot to Chat | Interactive region selection (like ⌘⇧4); the capture lands in the agent composer, ready to caption and send. |
| Screenshot to Terminal | Same selection, but the image file's path is typed into the focused terminal pane — as @/path when a CLI agent (Claude Code, codex, aider…) is running there, shell-escaped otherwise. Nothing is submitted; add your prompt and press Return. |
| Show Prompt Menu | Pop your saved Prompts as a menu at the terminal cursor. Picking one pastes it into that pane and presses Return; hold ⌥ for paste-only, and prompts with custom variables open the run sheet instead. |
| Attach File to Terminal | Open a file picker and type the paths you pick into the focused pane — @/path for a CLI agent, shell-escaped otherwise. See Attaching a file below. |
TRMNLY seeds four of these on first launch: ⌃⌘S → Screenshot to Chat and ⌃⇧⌘S → Screenshot to Terminal (both global), ⌘P → Show Prompt Menu, and ⌃⌘A → Attach File to Terminal (both in-app). Delete or re-record them freely — a deleted default is never re-added. (There's also a per-pane Screenshot for Agent… entry in the terminal's right-click menu when a CLI agent is running in that pane.)
Attaching a file to a terminal pane
Several ways in, all doing the same thing — no trip to Finder, no drag:
- The paperclip button at the right end of the folder strip above each terminal tab.
- ⌃⌘A (the seeded shortcut above), which acts on the focused pane.
- View → Attach File to Terminal… in the menu bar.
- Attach File to Terminal in the command palette (
⌘⇧P). - Attach File(s) for Agent… / Insert File Path(s)… in the pane's right-click menu.
Pick one or more files (or folders) and their paths are typed at the
cursor — as @/path when a CLI agent (Claude Code, codex, aider…) is the
foreground process in that pane, shell-escaped otherwise, so the result
is a file reference for the agent or a valid argument for cat/mv
either way. Nothing is submitted: add your prompt or the rest of the
command and press Return yourself.
The picker opens in the pane's project folder (or its working directory) the first time, then reopens wherever you last browsed. Dragging a file onto a pane still works and inserts identically.
Split tabs: one folder strip serves the whole tab, so the paperclip targets the focused pane — its tooltip names which one. Right-click the paperclip to get every pane listed by number (the same numbering the queue sidebar uses) and send the file to one you aren't focused on. The target is locked in when you press the button, so it still lands correctly if you click into another pane while the picker is open.
Creating one
- Settings → Shortcuts → Add Shortcut.
- Give it a Name.
- Click Record and press the chord ("Press a shortcut…"). Order
doesn't matter —
⇧⌘Rand⌘⇧Rare treated the same. - Pick the Action and fill in its field (the text, or the prompt/runbook to run — the screenshot actions need no field).
- Optionally enable Fire even when TRMNLY isn't focused (global) to make the chord work system-wide.
- Save.
How they fire
A chord triggers against the focused terminal window:
- Send Text goes to the focused pane.
- Run Saved Prompt / Run Runbook target the agent in the focused window, queueing any follow-up prompts.
- The Screenshot actions work well as global shortcuts: grab anything on screen from any app, and TRMNLY comes forward with the capture staged (in the chat composer, or typed at the terminal prompt).
- Attach File to Terminal opens its picker as a sheet on the focused terminal window, so it stays in-app rather than global.
If there's nothing to act on (no focused window, or a prompt/runbook that no longer exists), TRMNLY beeps rather than failing silently.
Global shortcuts (the checkbox above) fire even when another app is focused — handy for "drop a note into TRMNLY from anywhere." In-app shortcuts only fire while a TRMNLY window is focused.
Global shortcuts need macOS Accessibility permission to fire while another app is focused. If a global shortcut isn't firing, the Custom Shortcuts pane shows a banner linking to System Settings → Privacy & Security → Accessibility — grant TRMNLY there.
Custom shortcuts vs. Keybindings
Two settings panes, two jobs:
- Settings → Keybindings — rebind TRMNLY's built-in actions
(
new_tab,copy_to_clipboard,toggle_fullscreen, …) or bind any raw Ghostty action string. These flow through the config override file. See Keybinds. - Settings → Shortcuts — define new chords that run prompts, runbooks, text, screenshots, or the file picker. These live entirely in TRMNLY.
When you save a shortcut whose chord collides with another custom shortcut, a keybinding rebind, or a built-in menu shortcut, TRMNLY warns and asks before using it anyway.