Tutorial
Clipboard, snippets & pickers
Moving text in and out of a terminal is where a lot of small frictions hide. This walkthrough turns Sinclair's clipboard into a real tool: copy without selecting, pull back something you copied three commands ago, keep API keys off the clipboard for good, and fuzzy-find the commands, launch setups, and glyphs you reach for every day — then wire it all to two launchers you can drive by name.
On macOS, ⌘ is the modifier. On Linux, read ⌘ as ⌃ (Ctrl) throughout. Every shortcut here maps to an action you can remap — see Keybindings.
1. Copy & paste basics
The essentials are exactly where you expect: copy with ⌘C and paste with
⌘V. From there, two options make the clipboard feel native to a terminal.
Turn on copy-on-select and any selection is copied the moment you make
it — no keystroke — and turn on middle-click-paste to drop the current
selection with a middle click, the way X11 users already expect:
// ~/.config/sinclair/settings.json
{
"copy-on-select": true, // selecting text copies it immediately
"middle-click-paste": true // middle-click pastes the selection (X-style)
}
Remote programs get a say too: a process can set your clipboard through
OSC 52, so a tool running over SSH can copy to your local clipboard
without any round trip. That power cuts both ways on paste, which is why
clipboard-paste-protection warns you before pasting content that looks
risky — multi-line pastes and dangerous patterns like rm -rf,
curl … | sh, sudo, or writes to /dev — with
the reasons listed, so nothing runs before you've read it:
// ~/.config/sinclair/settings.json
{
"clipboard-paste-protection": true // confirm before pasting risky content
}
2. Clipboard history
The system clipboard only remembers the last thing you copied — Sinclair remembers a
ring of recent ones. Press ⌘⇧Y (clipboard_history) to open a
fuzzy picker over everything you've copied lately; type to filter, then choose an
entry to paste it into the focused pane. This is the fix for the copy-something-else
-and-lose-it problem: reach back and grab the value you copied three commands ago
without hunting through scrollback for it again.
3. Keep secrets off the clipboard
Copying a line that happens to hold an API key means that key now lives on your
clipboard, in your history, and one stray paste from a chat window. Secret redaction
stops that at the source. Each redact entry is a regular expression;
anything it matches is masked with bullets (•) before the text
ever reaches the clipboard:
// ~/.config/sinclair/settings.json
{
"redact": [
"sk-[A-Za-z0-9]{20,}", // mask OpenAI-style keys
"ghp_[A-Za-z0-9]{36}" // mask GitHub tokens
]
}
The key detail is that redaction runs on every copy path — an explicit ⌘C, copy-on-select, copy-command-output, and a copy-mode yank alike — so there's no gap where a secret slips through unmasked. Because it happens before the clipboard, the masked form is also what lands in clipboard history from step 2.
4. Snippets
Some commands you retype constantly and never quite remember in full. Save them as
snippets and recall them from a fuzzy picker instead. Each snippet entry
is label | command:
// ~/.config/sinclair/settings.json
{
"snippet": [
"deploy | git push origin main",
"logs | kubectl logs -f deploy/api"
]
}
Press ⌘⌥S (snippets) to open the picker and pick one. The
payoff is in what happens next: the picker inserts the command into the
focused pane rather than running it, so you can edit the arguments — swap the branch,
change the deployment — and only then press Enter. It's a starting point you tweak,
not a blind fire.
5. Launch profiles
Profiles are named launch setups — an SSH host, a REPL, a project environment. Each
profile entry is label | command, just like a snippet:
// ~/.config/sinclair/settings.json
{
"profile": [
"prod | ssh prod.example.com",
"repl | python3"
]
}
Press ⌘⌥P (profiles) to open the picker, and choosing one
opens a new tab running that command. The difference from a snippet
is deliberate: a snippet edits into your current pane, a profile spins up its own tab
and gets going — reach for it when you want the thing running, not staged.
6. Emoji & symbol picker
You don't need a separate app to type a glyph you can't reach on the keyboard. Press
⌘⌥E (unicode_picker) to open a searchable list of common emoji
and symbols — arrows, math signs, Greek letters, and more — each one named so you can
fuzzy-find it. Pick one and Sinclair sends the glyph straight to the focused pane. Handy
for a commit message, a comment, or a quick → in some notes.
7. Tie it together with the launchers
Every picker and action above is reachable by name, so you never have to memorize a keybinding to find a feature. Two launchers are the escape hatch:
| Shortcut | Opens | Use it to |
|---|---|---|
| ⌘P | Quick open (quick_open) | A Spotlight-style launcher; type a few letters and run any action — including the pickers above. |
| ⌘⇧P | Command palette (command_palette) | Fuzzy over Sinclair's full action catalog — the pickers, copy mode, splits, settings — with each row showing its current keybinding. |
Forgot that clipboard history is ⌘⇧Y? Open the command palette, type
clip, and run it — and the row shows you the shortcut for next time. The
launchers list everything, so the whole rest of this page is one ⌘⇧P away.