ConfigurationInterfaceTerminal setup

Terminal setup

Syntic Code works in any modern terminal without setup. A few small changes make it nicer: a key for new lines, Option-key shortcuts on a Mac, a ping when a long reply is ready, and a busy marker on the terminal tab. This page covers each one, plus pasting large text, vim keys, and running inside tmux.

New lines in the prompt

Enter sends your message. To start a new line instead:

KeyWorks in
\ then EnterEvery terminal.
Ctrl+JEvery terminal.
Shift+EnterTerminals that speak the enhanced keyboard protocol, or after /terminal-setup.
Alt+Enter (Option+Enter on a Mac)Terminals where Option or Alt is sent as Meta (see below).

/terminal-setup

Run /terminal-setup inside a session. It looks at which terminal you are in and does the right thing for it:

TerminalWhat happens
kitty, WezTerm, Ghostty, iTerm2 3.5 or laterNothing to install. Syntic Code turns on the enhanced keyboard protocol at start, so Shift+Enter already inserts a new line.
The terminal built into VS Code (and editors built on it)Adds a Shift+Enter binding to that editor’s keybindings.json. The rest of the file, comments included, is kept. An existing file is first copied to keybindings.json.bak (or .bak.1, .bak.2, …). Running it again changes nothing.
Alacritty, ZedPrints the binding to add to alacritty.toml or keymap.json yourself.
iTerm2 older than 3.5Explains that an update to 3.5 makes Shift+Enter work, and how to use Option+Enter until then.
macOS TerminalExplains why Shift+Enter cannot be told apart from Enter there, and how to use \ Enter or Option+Enter instead. Terminal’s settings are never changed.
Anything elseExplains which terminals support Shift+Enter and which keys work everywhere.

The terminal is recognised from TERM_PROGRAM, TERM and a few variables the terminal sets itself.

If Shift+Enter is already bound to something else in the editor’s keybindings.json, nothing is changed and you are told which command holds the key. Remove that binding and run /terminal-setup again. If the file is not a JSON list, it is left alone and reported.

Option-key shortcuts on a Mac

Several shortcuts use Alt: Alt+P (model picker), Alt+O (fast mode), Alt+T (reasoning on or off), Alt+B / Alt+F (word left / right), Alt+Enter (new line). On a Mac, Alt is the Option key, and these only reach Syntic Code when your terminal sends Option as Meta:

TerminalSetting
macOS TerminalSettings › Profiles › Keyboard › “Use Option as Meta key”.
iTerm2Settings › Profiles › Keys › set the Option key to “Esc+”.

Option+T works even without that setting.

Over SSH, Syntic Code guesses which keyboard you are typing on from the variables your terminal forwards, so the key names in hints match your keyboard. Set SYNTIC_CLIENT_PLATFORM to mac, linux or windows to say so yourself.

Notifications

When a turn finishes and you have stepped away, Syntic Code lets you know.

When it fires. If the terminal window is not focused, every finished turn counts. If it is focused, only turns that ran for 10 seconds or more count. Either way it waits about 6 seconds first, and any key you press in that time cancels it, since you are clearly still there. The message is “Response ready”.

How it is delivered depends on your terminal:

TerminalMethod
iTerm2A terminal notification escape (OSC 9).
kittykitty’s own desktop notification protocol.
Ghostty, foot, rxvtA terminal notification escape (OSC 777).
macOS Terminal and unrecognised terminals on macOSA macOS notification banner.
Unrecognised terminals elsewhereThe terminal bell.

Turn it off with the Notifications row in /config ("notificationsEnabled": false).

Choose the method yourself with SYNTIC_NOTIF_CHANNEL:

ValueSends
auto (default)The method in the table above.
iterm2OSC 9.
iterm2_with_bellOSC 9, then the bell.
terminal_bellOnly the bell.
kittykitty’s notification protocol.
ghosttyOSC 777.
notifications_disabledNothing.

An unknown value falls back to auto.

Your own sound or message. A Notification hook runs when a permission prompt is waiting for you (its notification_type is permission_prompt). For example, in ~/.syntic/settings.json:

{
  "hooks": {
    "Notification": [
      { "matcher": "permission_prompt", "hooks": [{ "type": "command", "command": "afplay /System/Library/Sounds/Glass.aiff" }] }
    ]
  }
}

Use any command that plays a sound or speaks on your system.

The terminal tab

Title

Syntic Code sets the terminal’s tab title to a short topic: the session’s name once it has one (/rename), otherwise the first words of your first prompt, otherwise the folder name. A small marker in front of it turns while a turn runs and stays still when Syntic Code is waiting for you. Set SYNTIC_DISABLE_TERMINAL_TITLE=1 to leave the title alone.

Progress marker

While a turn runs, Syntic Code sets the terminal’s own progress indicator (the OSC 9;4 sequence), which many terminals show on the tab or dock icon. It shows “paused” while a permission prompt waits, and clears when the turn ends. Terminals that do not understand it ignore it; it is skipped in terminals known to print it as text instead. Turn it off with Terminal progress bar in /config ("terminalProgressBarEnabled": false).

Pasting large text

Paste as much as you like. A paste longer than 800 characters or 8 lines is not dropped into the prompt box in full. Instead, a marker takes its place:

[Pasted text #1 +42 lines]

The full text is kept and sent when you press Enter. You can type around the marker, paste more (each paste gets its own number), and delete a marker like any other text to drop that paste. Shorter pastes go straight into the prompt.

Ctrl+V pastes an image from the clipboard; it shows as an [Image #1] marker.

Vim keys in the prompt

Turn on vim-style editing with /vim, the Editor mode row in /config, "vimMode": true, or SYNTIC_VIM_MODE=1. The prompt then starts in normal mode. The keys are listed on Keyboard shortcuts. Two related settings:

SettingEffect
vimInsertModeRemapsLeave insert mode by typing two keys quickly, for example {"jk": "<Esc>"}.
vimRegisterPersistKeep the yank register between sessions (on by default; text that looks like a secret is never saved).

tmux and screen

Syntic Code works inside tmux and GNU screen. Title changes, notifications, the progress marker and clipboard copies are wrapped so they pass through to your outer terminal. A plain bell is sent unwrapped, so tmux can flag the window as active.

Colors and width

NeedUse
Match a light or dark terminalThe default auto theme follows your terminal’s background. See Themes.
No colorNO_COLOR=1 or syntic --no-color.
Narrower reply text on a wide windowmaxProseWidth.
The full-screen view/tui fullscreen. See Full-screen mode.
A footer line from your own scriptSee Status line.
A screen readerSee Accessibility.

When it goes wrong

SymptomTry
Shift+Enter sends the messageRun /terminal-setup. Until it is fixed, use \ Enter or Ctrl+J.
Alt shortcuts type odd characters on a MacTurn on Option as Meta (above).
No notification arrivesCheck notificationsEnabled, then try SYNTIC_NOTIF_CHANNEL=terminal_bell to see whether your terminal is ignoring the escape. Some terminals need notifications allowed in their own settings or in the system’s notification settings.
Strange characters appear on the tab or in the output while a turn runsTurn off the progress marker ("terminalProgressBarEnabled": false).
The tab title fights with your shell’s titleSet SYNTIC_DISABLE_TERMINAL_TITLE=1.
The screen looks garbled after resizingPress Ctrl+L to redraw.

Every setting on this page can be found in the settings reference, and every variable in Environment variables.