Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions src/content/docs/cli/agent-conversations.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -56,15 +56,15 @@ For multi-step work, the agent tracks its progress with a task list rendered dir

Canceled tasks appear struck through. As the agent finishes tasks, compact confirmation rows (e.g., `✓ Completed <task> (2/5)`) track progress without repeating the whole list.

Task lists in the CLI reflect the same agent behavior as in the Warp app. Learn more about [how task lists work](/agent-platform/capabilities/task-lists/).
Task lists in the CLI reflect the same agent behavior as in the Warp app. Learn more about [how task lists work](/agents/capabilities/task-lists/).

## Planning

To have the agent first research and produce a plan before making changes, use the `/plan` slash command followed by a description of your task. You can also ask for a plan in natural language.

The plan renders inline in the transcript as a formatted document with its own header row showing the plan's status. An `Updated plan` entry appears when the agent revises it. Press `Ctrl+Shift+P` to expand or collapse the latest plan.

Planning in the CLI follows the same workflow as the Warp app. See [Planning](/agent-platform/capabilities/planning/) to learn how to create, review, and execute plans.
Planning in the CLI follows the same workflow as the Warp app. See [Planning](/agents/capabilities/planning/) to learn how to create, review, and execute plans.

## Selecting and copying output

Expand Down Expand Up @@ -142,5 +142,5 @@ After compaction, a collapsed **Conversation summary** block appears in the tran
* **[Running shell commands](/cli/shell-commands/)** - How commands the agent (or you) run appear in the transcript.
* **[Cloud handoff and orchestration](/cli/cloud-and-orchestration/)** - Hand off conversations to cloud agents and resume cloud runs.
* **[{VARS.WARP_CLI} reference](/cli/reference/)** - Command-line flags, slash commands, and keyboard shortcuts.
* **[Planning](/agent-platform/capabilities/planning/)** - The full planning workflow.
* **[Task lists](/agent-platform/capabilities/task-lists/)** - How agents create and update task lists.
* **[Planning](/agents/capabilities/planning/)** - The full planning workflow.
* **[Task lists](/agents/capabilities/task-lists/)** - How agents create and update task lists.
18 changes: 9 additions & 9 deletions src/content/docs/cli/configuration.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -107,16 +107,16 @@ The agent works in your session's current directory. When you `cd`, project rule

Within a project, the CLI picks up the same rule files as the Warp app:

* **Project rules** - `AGENTS.md` (or `WARP.md`) files in your repository apply automatically, starting from the repository root and your current directory. See [Rules](/agent-platform/capabilities/rules/) for the file format, nested rules in subdirectories, and precedence.
* **Project rules** - `AGENTS.md` (or `WARP.md`) files in your repository apply automatically, starting from the repository root and your current directory. See [Rules](/agents/capabilities/rules/) for the file format, nested rules in subdirectories, and precedence.
* **Global rules** - A rule file at `~/.agents/AGENTS.md` applies across all projects on your machine.

Because rules and skills come from the same shared locations, a repository already configured for agents in the Warp app (or any tool that reads `AGENTS.md`) works in the CLI immediately.

## Skills

[Skills](/agent-platform/capabilities/skills/) are reusable instruction sets the agent can invoke to perform specific tasks. The CLI discovers the same skills as the Warp app. Project skills come from your repository's skill directories (e.g., `.agents/skills/`), and personal skills come from your home directory (e.g., `~/.agents/skills/`), scoped to your current working directory.
[Skills](/agents/capabilities/skills/) are reusable instruction sets the agent can invoke to perform specific tasks. The CLI discovers the same skills as the Warp app. Project skills come from your repository's skill directories (e.g., `.agents/skills/`), and personal skills come from your home directory (e.g., `~/.agents/skills/`), scoped to your current working directory.

Run `/skills` to browse every skill in scope. Selecting a skill inserts `/skill-name` into the input so you can add extra instructions before running it. Any text after the skill name is passed along, either as [skill arguments](/agent-platform/capabilities/skills/#skill-arguments) or as additional context for the agent. You can also invoke a skill directly by typing `/` followed by its name, for example `/deploy push the latest changes to staging`.
Run `/skills` to browse every skill in scope. Selecting a skill inserts `/skill-name` into the input so you can add extra instructions before running it. Any text after the skill name is passed along, either as [skill arguments](/agents/capabilities/skills/#skill-arguments) or as additional context for the agent. You can also invoke a skill directly by typing `/` followed by its name, for example `/deploy push the latest changes to staging`.

### Bundled skills

Expand All @@ -127,9 +127,9 @@ The CLI ships with built-in skills that appear in the skills menu alongside your

## MCP servers

[MCP servers](/agent-platform/capabilities/mcp/) extend the agent with external tools and data sources. The CLI keeps its own MCP server configuration, separate from the Warp app's, so each can run its own set of servers.
[MCP servers](/agents/capabilities/mcp/) extend the agent with external tools and data sources. The CLI keeps its own MCP server configuration, separate from the Warp app's, so each can run its own set of servers.

Servers are defined in a JSON config file using the same `mcpServers` format as [file-based MCP servers](/agent-platform/capabilities/mcp/#file-based-mcp-servers) in the Warp app (on macOS, the file is `~/.warp_cli/.mcp.json`). Edit the file to add or remove servers. The CLI picks up changes automatically. Configured servers start automatically once you're logged in.
Servers are defined in a JSON config file using the same `mcpServers` format as [file-based MCP servers](/agents/capabilities/mcp/#file-based-mcp-servers) in the Warp app (on macOS, the file is `~/.warp_cli/.mcp.json`). Edit the file to add or remove servers. The CLI picks up changes automatically. Configured servers start automatically once you're logged in.

:::note
The CLI reads MCP servers from its global config file only. Project-scoped MCP config files in repositories are not detected. To copy global server definitions from the Warp app, use the `/tui-migrate-setup` bundled skill.
Expand All @@ -145,8 +145,8 @@ Press `Enter` on a server to start, stop, or retry it depending on its state. Fa

## Related pages

* [Rules](/agent-platform/capabilities/rules/) - Full guide to project and global rules
* [Skills](/agent-platform/capabilities/skills/) - Authoring skills, skill arguments, and skill locations
* [MCP servers](/agent-platform/capabilities/mcp/) - Config format, server examples, and authentication
* [Codebase Context](/agent-platform/capabilities/codebase-context/) - Codebase indexing in the Warp app
* [Rules](/agents/capabilities/rules/) - Full guide to project and global rules
* [Skills](/agents/capabilities/skills/) - Authoring skills, skill arguments, and skill locations
* [MCP servers](/agents/capabilities/mcp/) - Config format, server examples, and authentication
* [Codebase Context](/agents/capabilities/codebase-context/) - Codebase indexing in the Warp app
* [{VARS.WARP_CLI} reference](/cli/reference/) - Command-line flags, slash commands, and keyboard shortcuts
146 changes: 128 additions & 18 deletions src/content/docs/cli/input-and-editing.mdx
Original file line number Diff line number Diff line change
@@ -1,47 +1,157 @@
---
title: "Input and editing in the {{WARP_CLI}}"
title: "Input and shell commands in the Warp Agent CLI"
description: >-
The {{WARP_CLI}} input editor: slash commands, history, completions, mouse
support, images, voice input, and Vim mode.
Compose prompts, edit input, and run shell commands in the Warp Agent CLI,
including menus, history, completions, images, voice, and interactive
commands.
---
import { VARS } from '@data/vars';

{/* TODO(cli-input): draft per drafts/warp-cli-launch-plan.md — "cli/input-and-editing.mdx" section. Feature-doc content type. */}
The {VARS.WARP_CLI} is a full terminal as well as an agent: every session runs a real shell, so you can run commands in the same place you prompt the agent. The input is a multiline editor that combines readline-style editing with inline menus for slash commands, history, and completions, plus mouse support, image attachments, and voice input. For the complete list of flags, slash commands, and keyboard shortcuts, see the [{VARS.WARP_CLI} reference](/cli/reference/).

The {VARS.WARP_CLI} documentation for this page is in progress.
## Editing basics

The input is a multiline editor.

* **Insert a newline** - Press `Ctrl+J`, or `Shift+Enter` in terminals that support distinguishing it. `Alt+Enter` also works.
* **Edit with readline-style keys** - The editor supports familiar bindings such as `Ctrl+A` and `Ctrl+E` (start and end of line), `Ctrl+W` (delete the previous word), `Ctrl+K` and `Ctrl+U` (delete to the end or start of the line), `Ctrl+Y` (reinsert the last deleted text), and `Ctrl+Z` (undo).
* **Use macOS Command shortcuts** - When the Kitty keyboard protocol is enabled in your terminal, the editor supports Command-modified shortcuts such as `⌘+X` to cut and `⌘+Shift+←` or `⌘+Shift+→` to extend the selection.

The full editing and selection table is in the [keyboard shortcuts reference](/cli/reference/#keyboard-shortcuts).

:::note
Core `Ctrl` and `Alt` bindings are cross-platform. Shortcuts that use `Alt` require some macOS terminals' Option-as-Alt (Meta) setting. Command-modified shortcuts require a terminal with the Kitty keyboard protocol enabled.
:::

## Slash commands

{/* TODO(cli-input): slash command menu, filtering, argument hints; link to reference page for the full table. */}
Type `/` at the start of an empty input to open the slash command menu. Entries for toggles and pickers show their current state, for example `/theme (currently auto: Dark)` or `/auto-approve (currently off)`.

## Prompt history
When a command takes an argument, the input shows a ghost-text argument hint after the full command name, for example `/theme <auto|light|dark>`.

{/* TODO(cli-input): up-arrow history for prompts and shell commands. */}
Your [skills](/cli/configuration/#skills) also appear in the slash command menu, so you can invoke a skill by typing `/` followed by its name.

## Tab completions
The [slash commands reference](/cli/reference/#slash-commands) lists every command.

{/* TODO(cli-input): completions for shell commands — confirm shipped before merge. */}
## Input history

## Mouse support
Press `↑` with the cursor on the first row of the input to open the history menu.

{/* TODO(cli-input): text selection in the input, clicking inline menu rows, selection persistence. */}
* **What's listed** - In agent mode, the menu combines your previous prompts and shell commands in one list, with commands marked by a `!` prefix. In [shell mode](#shell-mode), the menu lists commands only.
* **Preview** - Moving the selection previews each entry in the input and switches the input to the matching mode: recalled commands run as shell commands, and recalled prompts go to the agent.
* **Submit** - `Enter` runs the selection immediately; it doesn't insert it for editing.
* **Dismiss** - `Esc` restores what you had typed; `↓` past the newest entry does the same.

## Tab completions

In [shell mode](#shell-mode), press `Tab` to complete the command you're typing, including file and directory paths.

* If exactly one completion matches, the CLI applies it immediately.
* If several completions match, the CLI inserts the longest shared prefix and opens a completion menu. Press `Tab` again to cycle through the suggestions.

## Selection and clipboard

{/* TODO(cli-input): copying, opt-in auto-copy of highlighted input text. */}
* **Highlight to copy** - Finishing a mouse selection in the input or the [conversation transcript](/cli/agent-conversations/) automatically copies it.
* **Keyboard selection** - Extend the selection with `Shift` plus the arrow keys, or select everything with `Ctrl+Shift+A`. Copy with `Ctrl+Shift+C` and cut with `Ctrl+X`.
* **Paste** - Press `Ctrl+V` or `Ctrl+Shift+V` (also `Alt+V` on Windows). Your terminal's own paste shortcut works as well.
* **Click controls** - Interactive elements such as the **Voice** footer entry and the attachment bar controls respond to clicks.

:::note
Copying works over SSH: on remote sessions the CLI writes the clipboard through the OSC 52 escape sequence (including tmux passthrough), so your local clipboard receives the text when your terminal supports OSC 52.
:::

## Attach images

{/* TODO(cli-input): attaching images as context. */}
Attach images to a prompt so the agent can analyze them:

* **Paste an image** - Copy an image to your clipboard and press `Ctrl+V`.
* **Paste or drop a file path** - Paste the path to an image file, or drag the file onto your terminal window to insert its path. Absolute paths, paths relative to the working directory, and `~` paths all resolve.

Supported formats are PNG, JPEG, GIF, and WebP. Attaching an image locks the input to agent mode, since images are sent to the agent rather than the shell.

Attached images appear in an attachment bar above the input. Press `Tab` to focus the bar, `Backspace` to remove the selected attachment, and `Esc` to return to the input.

## Voice input

{/* TODO(cli-input): /voice, `Ctrl+S`, configurable keybinding; cross-link voice docs. */}
Dictate prompts instead of typing them:

:::caution
Voice input isn't currently included in the official Linux build. Linux support is planned.
:::

## Vim mode
1. Start listening with `Ctrl+S`, the `/voice` slash command, or by clicking **Voice** in the footer. The footer shows **Listening** while recording.
2. Press `Enter`, or click the footer entry again, to stop recording. The transcribed text lands in the input so you can review and edit it before submitting.

{/* TODO(cli-input): vim input mode — confirm shipped before merge. */}
Press `Esc` while transcription is in progress to cancel it. `/voice` clears the input before recording; `Ctrl+S` keeps what you've already typed.

Voice input in the CLI uses the same transcription service as the Warp app. See [voice input for agents](/agents/local-agents/interacting-with-agents/voice/) for microphone setup, privacy, and usage limits.

## Keyboard hints and the shortcuts menu

{/* TODO(cli-input): ghost-text hints in the input, shortcuts menu. */}
The CLI shows its shortcuts in context, so you rarely need to memorize them:

* **Placeholder hints** - An empty input shows the key triggers for the current mode.
* **Shortcuts menu** - Type `?` in an empty input to open a shortcuts overview. Its contents adapt to what you're doing: agent mode lists the menu triggers and input history, shell mode shows how to return to agent mode, and extra sections appear during multi-agent sessions or agent-controlled terminal use. Press `Esc`, or start typing, to close it.

## Shell mode

The input is agent-first: by default, pressing `Enter` sends your text to the agent as a prompt. Use shell mode to run a command instead:

1. Press `!` at the start of the input. The prompt marker changes from `>` to `!`, and the statusline below the input shows **Shell mode**.
2. Run a command. The input returns to agent mode afterward.

To leave shell mode without running a command, press `Esc`, or press `Backspace` at the start of the input. Any text you typed stays in the input.

In shell mode, press `Tab` to complete commands and paths; see [Tab completions](#tab-completions).

:::note
Running a shell command cancels the agent's in-progress response, if there is one.
:::

## Natural language detection

Out of the box, the CLI never guesses what your input is: everything goes to the agent unless you enter shell mode. To type commands directly without the `!` prefix, turn on natural language detection:

- **Toggle detection** - Run `/natural-language-detection` to turn detection on or off. The statusline confirms the change, and the setting persists across sessions.
- **Automatic classification** - With detection on, the CLI classifies your input as you type. When the input looks like a shell command (for example, `git status`), the input switches to shell mode, and `Enter` runs it as a command. Everything else is sent to the agent.
- **Ambiguous input** - Short or ambiguous input stays in agent mode, and a single word switches to shell mode only when it matches a command available in your shell.

The prompt marker and statusline always show the current mode before you press `Enter`. If detection classifies input differently than you intended, press `Esc` to switch back to agent mode, or press `!` at the start of the input to force shell mode.

## Long-running and interactive commands

When a command keeps running, such as a dev server, a package install, or an interactive prompt, the CLI hands input over to it:

- **Input passthrough** - Keystrokes and pasted text are forwarded to the running process, so password requests, confirmation prompts, and other interactive programs work as they do in a plain terminal.
- **Type ahead** - If you start typing your next command before the current one finishes, the typed characters are carried into the input when the command completes, with the cursor at the end. This matches type-ahead behavior in shells like zsh and bash.

One command runs in the session at a time. If the terminal is already busy, for example while the agent is running a command of its own, submitting a shell command shows a notice in the statusline and keeps your text in the input.

## Full-screen terminal apps

Commands that switch the terminal to the alternate screen, such as `vim`, `htop`, or `less`, take over the whole CLI view:

- The app renders full-screen and receives keyboard, paste, scroll, and mouse input, so editors and other terminal UIs are fully usable inside the CLI.
- When the app exits, the transcript returns with your conversation intact.

## Stopping commands and exiting

`Ctrl+C` performs one contextual action per press:

- **While a command is running** - `Ctrl+C` interrupts the running command, as in a plain terminal. It doesn't exit the CLI.
- **While the agent is responding** - `Ctrl+C` cancels the in-progress response. Text in the input is preserved.
- **At an idle prompt** - `Ctrl+C` clears the input if it has text.

After a press at the prompt, the statusline shows `ctrl-c again to exit` for about one second. Press `Ctrl+C` a second time within that window to exit the CLI. This works even while the agent is responding; while a shell command is running, `Ctrl+C` keeps interrupting the command instead.

There are two other ways to exit:

- **`Ctrl+D`** - Exits immediately when the input is empty.
- **`/exit`** - Exits from the slash command menu.

When you exit, the CLI prints a command you can use to pick the conversation back up later. See [Managing conversations](/cli/agent-conversations/#managing-conversations) for resuming and switching conversations.

## Related pages

* [{VARS.WARP_CLI} reference](/cli/reference/) - Flags, environment variables, slash commands, and keyboard shortcuts.
* [Agent conversations in the {VARS.WARP_CLI}](/cli/agent-conversations/) - The transcript, tool calls, diffs, and managing conversations.
Loading
Loading