On this page
Terminals
/terminal opens a full-screen shell in your project folder, inside the TUI. It is for your own
commands: a dev server, a long build, a quick look around. You can step back to the chat and the
shell keeps running.
Open a terminal
- Run
/terminal. - Use the shell as usual. It is your
$SHELL, started in the project folder. - Press Ctrl+] (or F12) to return to the chat. The status line says the processes are still running.
Run /terminal again to come back. The tab reconnects and replays recent output (the last 2 MiB),
so you see where it got to rather than a blank screen.
More than one tab
/terminal new, or Ctrl+Shift+T inside a terminal, opens another tab. Every tab you have
open comes back when you return with /terminal.
Some terminals cannot send Ctrl+Shift+T and Ctrl+Shift+W; there those keys go to the shell, and
the footer of the terminal view leaves them out. Use /terminal new to open a tab, and exit in
the shell to close one.
Keys in a terminal
| Key | Does |
|---|---|
| Ctrl+] or F12 | Back to the chat; the shell keeps running |
| Ctrl+Shift+T | New tab |
| Ctrl+Shift+W | Close the current tab and end its processes |
| Alt+←, Alt+→ | Previous, next tab |
| Shift+Page Up, Shift+Page Down | Scroll back through output |
Every other key goes to the shell, Ctrl+C included. Ctrl+] also works inside tmux. If your
keyboard needs another key to type ], use F12.
When does a terminal stop?
A tab keeps running when you return to the chat, close the TUI, or switch chats, because the Haarness server for this folder owns it, not the window. Other clients attached to the same server see the same tabs.
It stops when you close it with Ctrl+Shift+W, when its shell exits, or when the Haarness server stops. A tab whose shell exits closes; when the last one closes, you are back in the chat.
Terminal tabs and the agent's commands
Commands the agent runs are separate. They go through permissions and time limits, and show up in the transcript. A terminal tab is yours: nothing you type there asks for approval.
rg (ripgrep) is available in both without installing it.
Related
- Run a shell command yourself: one command, with its output in the chat
- Goals: keep the agent working until an objective is met