Skip to content
Merged
Show file tree
Hide file tree
Changes from 128 commits
Commits
Show all changes
137 commits
Select commit Hold shift + click to select a range
d23824d
Changeset version bump (#10451)
github-actions[bot] Jan 4, 2026
cbc0ae4
feat: add image support documentation to read_file native tool descri…
Jan 5, 2026
f2276be
fix: add explicit deduplication for duplicate tool_result blocks (#10…
Jan 5, 2026
b11d53a
VSCode shim + basic cli (#10452)
cte Jan 5, 2026
424bce6
Add an option to use our cli for evals (#10456)
cte Jan 5, 2026
6f09481
fix: preserve tool_use blocks for all tool_results in kept messages d…
daniel-lxs Jan 6, 2026
6b13d1d
fix: add additionalProperties: false to MCP tool schemas for OpenAI R…
daniel-lxs Jan 6, 2026
861139c
Add a cli installer (#10474)
cte Jan 6, 2026
503f402
feat(proxy): add debug-mode proxy routing (#10467)
hannesrudolph Jan 6, 2026
741b268
fix: prevent duplicate tool_result blocks causing API errors (#10497)
daniel-lxs Jan 6, 2026
781ed1e
feat: add Kimi K2 thinking model to Fireworks AI provider (#9202)
Jan 7, 2026
7f2978a
fix: add missing description fields for debugProxy configuration (#10…
Jan 7, 2026
2d22804
Tweak the style of the follow up suggestion modes (#9260)
mrubens Jan 7, 2026
41c5ff6
feat(web-evals): remember last Roo model selection + add evals skill …
hannesrudolph Jan 7, 2026
7bbdcdf
feat: rename YOLO to BRRR (#10507)
Jan 7, 2026
9700eab
feat: implement sticky provider profile for task-level API config per…
hannesrudolph Jan 7, 2026
e287a82
fix: remove legacy Claude 2 series models from Bedrock provider (#10501)
Jan 7, 2026
43f7ce0
feat: add support for image file @mentions (#10189)
hannesrudolph Jan 7, 2026
d7d3f40
fix: handle PowerShell ENOENT error in os-name on Windows (#9897)
Jan 7, 2026
e3b90fb
feat: add xhigh reasoning effort to OpenAI compatible endpoints (#10061)
Jan 7, 2026
7552581
feat: filter @ mention file search results using .rooignore (#10174)
Jan 7, 2026
ca0c901
fix: use task stored API config as fallback for rate limit (#10266)
Jan 8, 2026
1573edf
fix: make command chaining examples shell-aware for Windows compatibi…
Jan 8, 2026
710e7dd
feat(types): add zai-glm-4.7 to Cerebras models (#10500)
sebastiand-cerebras Jan 8, 2026
b2941d5
🐛 Fix glitchy kangaroo bounce animation on welcome screen (#10035)
objectiveSee Jan 8, 2026
f84bead
Release v3.39.0 (#10537)
mrubens Jan 8, 2026
a10b450
feat: Change "Get Started" button label to "Create Roo Account" (#10543)
Jan 8, 2026
9ddbc9b
fix: add @roo-code/cli to changeset ignore list (#10545)
mrubens Jan 8, 2026
2cd4c2e
Changeset version bump (#10546)
github-actions[bot] Jan 8, 2026
93bccfe
Update changelog for version 3.39.0 release
mrubens Jan 8, 2026
1d9f7f2
fix: change minItems from 2 to 1 for Anthropic API compatibility (#10…
daniel-lxs Jan 8, 2026
e3c0cd6
fix: disable Gemini thought signature persistence to prevent corrupte…
daniel-lxs Jan 8, 2026
ef4b950
fix: stabilize file paths during native tool call streaming (#10555)
daniel-lxs Jan 8, 2026
58b0441
Release v3.39.1 (#10557)
mrubens Jan 8, 2026
eb7d8f4
Changeset version bump (#10558)
github-actions[bot] Jan 8, 2026
caa3779
chore(cli): change default model to anthropic/claude-opus-4.5 (#10544)
mrubens Jan 8, 2026
9ac4499
fix: ensure assistant message content is never undefined for Gemini c…
daniel-lxs Jan 9, 2026
2ff08b5
Update Terms of Service (effective January 9, 2026) (#10568)
mrubens Jan 9, 2026
ade10e2
fix(vscode-lm): order text parts before tool calls in assistant messa…
daniel-lxs Jan 9, 2026
7b771a2
fix: merge approval feedback into tool result instead of pushing dupl…
daniel-lxs Jan 9, 2026
b7bd859
feat: improve error messaging for stream termination errors from prov…
daniel-lxs Jan 9, 2026
907b94b
fix(openai): remove convertToSimpleMessages to fix tool calling for O…
daniel-lxs Jan 9, 2026
3171ffc
Move more types to @roo-code/types (for the cli) (#10583)
cte Jan 9, 2026
a4eb15b
Add some functionality to @roo-code/core for the cli (#10584)
cte Jan 9, 2026
237fa89
Add some slash commands that are useful for cli development (#10586)
cte Jan 9, 2026
108f78d
feat: add debug setting to settings page (#10580)
hannesrudolph Jan 9, 2026
168cfca
fix: round-trip Gemini thought signatures for tool calls (#10590)
hannesrudolph Jan 10, 2026
e39abbf
fix: make edit_file matching more resilient (#10585)
hannesrudolph Jan 10, 2026
8478944
chore(gemini): stop overriding tool allow/deny lists (#10592)
hannesrudolph Jan 10, 2026
d97e540
fix(cerebras): ensure all tools have consistent strict mode values (#…
Jan 10, 2026
5a82c33
chore: disable edit_file tool for Gemini/Vertex (#10594)
hannesrudolph Jan 10, 2026
658da2c
Release v3.39.2 (#10595)
mrubens Jan 10, 2026
1e62b5d
Changeset version bump (#10596)
github-actions[bot] Jan 10, 2026
ea9717d
Add a TUI (#10480)
cte Jan 10, 2026
e8ed344
Allow the cli release script to install locally for testing (#10597)
cte Jan 10, 2026
fc21101
More file organization for the cli (#10599)
cte Jan 10, 2026
a33117a
Some cleanup in ExtensionHost (#10600)
cte Jan 10, 2026
75d8958
Rename Roo Code Cloud Provider to Roo Code Router (#10560)
Jan 10, 2026
f99d116
chore: bump version to v1.102.0 (#10604)
mrubens Jan 10, 2026
fa5fe75
Update router name in types (#10605)
mrubens Jan 10, 2026
352616a
Update Roo Code Router service name (#10607)
mrubens Jan 10, 2026
9c91fb3
chore: add changeset for v3.39.3 (#10608)
mrubens Jan 10, 2026
f1bbd29
Update router name in types (#10610)
mrubens Jan 10, 2026
611bb70
Changeset version bump (#10609)
github-actions[bot] Jan 10, 2026
632b86c
Basic settings search (#10619)
mrubens Jan 11, 2026
e23e1ec
ux: UI improvements to search settings (#10633)
brunobergher Jan 12, 2026
4c2d1f0
feat: display edit_file errors in UI after consecutive failures (#10581)
daniel-lxs Jan 12, 2026
55b7324
perf: optimize message block cloning in presentAssistantMessage (#10616)
ArchimedesCrypto Jan 12, 2026
f439496
fix: correct Gemini 3 thought signature injection format via OpenRout…
daniel-lxs Jan 12, 2026
a682908
fix: encode hyphens in MCP tool names before sanitization (#10644)
pdecat Jan 12, 2026
621d950
fix: sanitize tool_use IDs to match API validation pattern (#10649)
daniel-lxs Jan 12, 2026
b514996
fix(path): return empty string from getReadablePath when path is empt…
daniel-lxs Jan 12, 2026
a12163d
ux: Standard stop button 🟥 (#10639)
brunobergher Jan 13, 2026
2d4dba0
fix: omit parallel_tool_calls when not explicitly enabled (COM-406) (…
daniel-lxs Jan 13, 2026
78821a3
fix: use placeholder for empty tool result content to fix Gemini API …
daniel-lxs Jan 13, 2026
749026a
ux: Further improve error display (#10692)
brunobergher Jan 13, 2026
8303710
ux: improve stop button visibility and streamline error handling (#10…
brunobergher Jan 13, 2026
440924a
fix: clear approval buttons when API request starts (ROO-526) (#10702)
daniel-lxs Jan 13, 2026
fdc6104
chore: add changeset for v3.40.0 (#10705)
mrubens Jan 13, 2026
d74bad9
Changeset version bump (#10706)
github-actions[bot] Jan 13, 2026
9b1c850
feat(gemini): add allowedFunctionNames support to prevent mode switch…
hannesrudolph Jan 14, 2026
8fdd96b
Release v3.40.1 (#10713)
mrubens Jan 14, 2026
d689de3
Changeset version bump (#10714)
github-actions[bot] Jan 14, 2026
4b17f98
Release: v1.105.0 (#10722)
mrubens Jan 14, 2026
b04597f
feat(providers): add gpt-5.2-codex model to openai-native provider (#…
hannesrudolph Jan 14, 2026
dbf206f
feat(e2e): Enable E2E tests - 39 passing tests (#10720)
ArchimedesCrypto Jan 14, 2026
739b91e
Clear terminal output buffers to prevent memory leaks (#7666)
hannesrudolph Jan 15, 2026
4ebbca0
feat: add OpenAI Codex provider with OAuth subscription authenticatio…
hannesrudolph Jan 15, 2026
d7b7e17
fix(litellm): inject dummy thought signatures on ALL tool calls for G…
daniel-lxs Jan 15, 2026
dba76f5
fix(e2e): add alwaysAllow config for MCP time server tools (#10733)
ArchimedesCrypto Jan 15, 2026
afc588b
Release v3.41.0 (#10746)
mrubens Jan 15, 2026
5183be2
Changeset version bump (#10747)
github-actions[bot] Jan 15, 2026
724571c
feat: clarify Slack and Linear are Cloud Team only features (#10748)
Jan 15, 2026
4ee494b
Release: v1.106.0 (#10749)
mrubens Jan 15, 2026
f2b16d4
fix: handle missing tool identity in OpenAI Native streams (#10719)
hannesrudolph Jan 15, 2026
f48ea38
Feat/issue 5376 aggregate subtask costs (#10757)
taltas Jan 15, 2026
245e0f6
feat: add settings tab titles to search index (#10761)
Jan 16, 2026
bbf3196
fix: filter Ollama models without native tool support (#10735)
daniel-lxs Jan 16, 2026
3a884ee
fix: filter out empty text blocks from user messages for Gemini compa…
daniel-lxs Jan 16, 2026
df42655
fix: flatten top-level anyOf/oneOf/allOf in MCP tool schemas (#10726)
daniel-lxs Jan 16, 2026
bbb6a6e
fix: prevent duplicate tool_use IDs causing API 400 errors (#10760)
daniel-lxs Jan 16, 2026
e34d93e
fix: truncate call_id to 64 chars for OpenAI Responses API (#10763)
daniel-lxs Jan 16, 2026
ddac338
fix: Gemini thought signature validation errors (#10694)
daniel-lxs Jan 16, 2026
7e3fcd7
Release v3.41.1 (#10767)
mrubens Jan 16, 2026
8b9f02a
Changeset version bump (#10768)
github-actions[bot] Jan 16, 2026
9bf7173
feat: add button to open markdown in VSCode preview (#10773)
brunobergher Jan 16, 2026
9533f0b
fix(openai-codex): reset invalid model selection (#10777)
hannesrudolph Jan 16, 2026
c40c882
fix: add openai-codex to providers that don't require API key (#10786)
Jan 16, 2026
95be704
fix(litellm): detect Gemini models with space-separated names for tho…
daniel-lxs Jan 16, 2026
cad0320
Release v3.41.2 (#10788)
mrubens Jan 16, 2026
99a9950
changeset version bump
github-actions[bot] Jan 16, 2026
8d26940
Update CHANGELOG.md
mrubens Jan 16, 2026
aa29ea0
Merge branch 'upstream-at-v3.41.2' into roo-v3.41.2
kevinvandijk Jan 20, 2026
eb2c770
Remove duplicate entry
kevinvandijk Jan 20, 2026
ba16412
Add missing import
kevinvandijk Jan 20, 2026
66e26a6
Fix imports in getTaskHistory
kevinvandijk Jan 20, 2026
f3f6f7a
Fix typing
kevinvandijk Jan 20, 2026
c9204df
Fix linting errors
kevinvandijk Jan 20, 2026
b798fc3
Fix for new types
kevinvandijk Jan 20, 2026
95a3303
Fix circular dependency
kevinvandijk Jan 20, 2026
22a91d9
Add kilo specific mocks
kevinvandijk Jan 20, 2026
3bd3af5
Use the right referer
kevinvandijk Jan 20, 2026
3a43c9f
Fix setting headers
kevinvandijk Jan 20, 2026
7513a76
Merge branch 'main' into roo-v3.41.2
kevinvandijk Jan 20, 2026
922b984
Update translations
kevinvandijk Jan 20, 2026
95d840c
Remove .roo dir
kevinvandijk Jan 20, 2026
be260c8
Fix webview tests
kevinvandijk Jan 20, 2026
58cd7fe
Merge branch 'main' into roo-v3.41.2
chrarnoldus Jan 21, 2026
6947993
Update user agent
kevinvandijk Jan 21, 2026
7f6f156
Merge branch 'main' into roo-v3.41.2
kevinvandijk Jan 21, 2026
db3dc2c
Fix test
kevinvandijk Jan 21, 2026
015e1e0
Re-add cancel button
kevinvandijk Jan 21, 2026
25e9c44
Merge branch 'main' into roo-v3.41.2
kevinvandijk Jan 21, 2026
52ebb1c
Make autocomplete settings searchable
kevinvandijk Jan 22, 2026
19ad8fd
Add missing translations
kevinvandijk Jan 23, 2026
2bd633c
Merge branch 'main' into roo-v3.41.2
kevinvandijk Jan 26, 2026
796e188
Add changeset
kevinvandijk Jan 26, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 1 addition & 1 deletion .changeset/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@
"access": "restricted",
"baseBranch": "main",
"updateInternalDependencies": "patch",
"ignore": []
"ignore": ["@roo-code/cli"]
}
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -71,3 +71,5 @@ qdrant_storage/
.secrets
# Architect plans
./plans/

roo-cli-*.tar.gz*
116 changes: 116 additions & 0 deletions apps/cli/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,116 @@
# Changelog

All notable changes to the `@roo-code/cli` package will be documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [0.0.45] - 2026-01-08

### Changed

- **Major Refactor**: Extracted ~1400 lines from [`App.tsx`](src/ui/App.tsx) into reusable hooks and utilities for better maintainability:

- [`useExtensionHost`](src/ui/hooks/useExtensionHost.ts) - Extension host connection and lifecycle management
- [`useMessageHandlers`](src/ui/hooks/useMessageHandlers.ts) - Message processing and state updates
- [`useTaskSubmit`](src/ui/hooks/useTaskSubmit.ts) - Task submission logic
- [`useGlobalInput`](src/ui/hooks/useGlobalInput.ts) - Global keyboard shortcut handling
- [`useFollowupCountdown`](src/ui/hooks/useFollowupCountdown.ts) - Auto-approval countdown logic
- [`useFocusManagement`](src/ui/hooks/useFocusManagement.ts) - Input focus state management
- [`usePickerHandlers`](src/ui/hooks/usePickerHandlers.ts) - Picker component event handling
- [`uiStateStore`](src/ui/stores/uiStateStore.ts) - UI-specific state (showExitHint, countdown, etc.)
- Tool data utilities ([`extractToolData`](src/ui/utils/toolDataUtils.ts), `formatToolOutput`, etc.)
- [`HorizontalLine`](src/ui/components/HorizontalLine.tsx) component

- **Performance Optimizations**:

- Added RAF-style scroll throttling to reduce state updates
- Stabilized `useExtensionHost` hook return values with `useCallback`/`useMemo`
- Added streaming message debouncing to batch rapid partial updates
- Added shallow array equality checks to prevent unnecessary re-renders

- Simplified [`ModeTool`](src/ui/components/tools/ModeTool.tsx) layout to horizontal with mode suffix
- Simplified logging by removing verbose debug output and adding first/last partial message logging pattern
- Updated Nerd Font icon codepoints in [`Icon`](src/ui/components/Icon.tsx) component

### Added

- `#` shortcut in help trigger for quick access to task history autocomplete

### Fixed

- Fixed a crash in message handling
- Added protected file warning in tool approval prompts
- Enabled `alwaysAllowWriteProtected` for non-interactive mode

### Removed

- Removed unused `renderLogger.ts` utility file

### Tests

- Updated extension-host tests to expect `[Tool Request]` format
- Updated Icon tests to expect single-char Nerd Font icons

## [0.0.44] - 2026-01-08

### Added

- **Tool Renderer Components**: Specialized renderers for displaying tool outputs with optimized formatting for each tool type. Each renderer provides a focused view of its data structure.

- [`FileReadTool`](src/ui/components/tools/FileReadTool.tsx) - Display file read operations with syntax highlighting
- [`FileWriteTool`](src/ui/components/tools/FileWriteTool.tsx) - Show file write/edit operations with diff views
- [`SearchTool`](src/ui/components/tools/SearchTool.tsx) - Render search results with context
- [`CommandTool`](src/ui/components/tools/CommandTool.tsx) - Display command execution with output
- [`BrowserTool`](src/ui/components/tools/BrowserTool.tsx) - Show browser automation actions
- [`ModeTool`](src/ui/components/tools/ModeTool.tsx) - Display mode switching operations
- [`CompletionTool`](src/ui/components/tools/CompletionTool.tsx) - Show task completion status
- [`GenericTool`](src/ui/components/tools/GenericTool.tsx) - Fallback renderer for other tools

- **History Trigger**: New `#` trigger for task history autocomplete with fuzzy search support. Type `#` at the start of a line to browse and resume previous tasks.

- [`HistoryTrigger.tsx`](src/ui/components/autocomplete/triggers/HistoryTrigger.tsx) - Trigger implementation with fuzzy filtering
- Shows task status, mode, and relative timestamps
- Supports keyboard navigation for quick task selection

- **Release Confirmation Prompt**: The release script now prompts for confirmation before creating a release.

### Fixed

- Task history picker selection and navigation issues
- Mode switcher keyboard handling bug

### Changed

- Reorganized test files into `__tests__` directories for better project structure
- Refactored utility modules into dedicated `utils/` directory

## [0.0.43] - 2026-01-07

### Added

- **Toast Notification System**: New toast notifications for user feedback with support for info, success, warning, and error types. Toasts auto-dismiss after a configurable duration and are managed via Zustand store.

- New [`ToastDisplay`](src/ui/components/ToastDisplay.tsx) component for rendering toast messages
- New [`useToast`](src/ui/hooks/useToast.ts) hook for managing toast state and displaying notifications

- **Global Input Sequences Registry**: Centralized system for handling keyboard shortcuts at the application level, preventing conflicts with input components.

- New [`globalInputSequences.ts`](src/ui/utils/globalInputSequences.ts) utility module
- Support for Kitty keyboard protocol (CSI u encoding) for better terminal compatibility
- Built-in sequences for `Ctrl+C` (exit) and `Ctrl+M` (mode cycling)

- **Local Tarball Installation**: The install script now supports installing from a local tarball via the `ROO_LOCAL_TARBALL` environment variable, useful for offline installation or testing pre-release builds.

### Changed

- **MultilineTextInput**: Updated to respect global input sequences, preventing the component from consuming shortcuts meant for application-level handling.

### Tests

- Added comprehensive tests for the toast notification system
- Added tests for global input sequence matching

## [0.0.42] - 2025-01-07

The cli is alive!
262 changes: 262 additions & 0 deletions apps/cli/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,262 @@
# @roo-code/cli

Command Line Interface for Roo Code - Run the Roo Code agent from the terminal without VSCode.

## Overview

This CLI uses the `@roo-code/vscode-shim` package to provide a VSCode API compatibility layer, allowing the main Roo Code extension to run in a Node.js environment.

## Installation

### Quick Install (Recommended)

Install the Roo Code CLI with a single command:

```bash
curl -fsSL https://raw.githubusercontent.com/RooCodeInc/Roo-Code/main/apps/cli/install.sh | sh
```

**Requirements:**

- Node.js 20 or higher
- macOS (Intel or Apple Silicon) or Linux (x64 or ARM64)

**Custom installation directory:**

```bash
ROO_INSTALL_DIR=/opt/roo-code ROO_BIN_DIR=/usr/local/bin curl -fsSL ... | sh
```

**Install a specific version:**

```bash
ROO_VERSION=0.1.0 curl -fsSL https://raw.githubusercontent.com/RooCodeInc/Roo-Code/main/apps/cli/install.sh | sh
```

### Updating

Re-run the install script to update to the latest version:

```bash
curl -fsSL https://raw.githubusercontent.com/RooCodeInc/Roo-Code/main/apps/cli/install.sh | sh
```

### Uninstalling

```bash
rm -rf ~/.roo/cli ~/.local/bin/roo
```

### Development Installation

For contributing or development:

```bash
# From the monorepo root.
pnpm install

# Build the main extension first.
pnpm --filter roo-cline bundle

# Build the cli.
pnpm --filter @roo-code/cli build
```

## Usage

### Interactive Mode (Default)

By default, the CLI prompts for approval before executing actions:

```bash
export OPENROUTER_API_KEY=sk-or-v1-...

roo ~/Documents/my-project -P "What is this project?"
```

You can also run without a prompt and enter it interactively in TUI mode:

```bash
roo ~/Documents/my-project
```

In interactive mode:

- Tool executions prompt for yes/no approval
- Commands prompt for yes/no approval
- Followup questions show suggestions and wait for user input
- Browser and MCP actions prompt for approval

### Non-Interactive Mode (`-y`)

For automation and scripts, use `-y` to auto-approve all actions:

```bash
roo ~/Documents/my-project -y -P "Refactor the utils.ts file"
```

In non-interactive mode:

- Tool, command, browser, and MCP actions are auto-approved
- Followup questions show a 60-second timeout, then auto-select the first suggestion
- Typing any key cancels the timeout and allows manual input

### Roo Code Cloud Authentication

To use Roo Code Cloud features (like the provider proxy), you need to authenticate:

```bash
# Log in to Roo Code Cloud (opens browser)
roo auth login

# Check authentication status
roo auth status

# Log out
roo auth logout
```

The `auth login` command:

1. Opens your browser to authenticate with Roo Code Cloud
2. Receives a secure token via localhost callback
3. Stores the token in `~/.config/roo/credentials.json`

Tokens are valid for 90 days. The CLI will prompt you to re-authenticate when your token expires.

**Authentication Flow:**

```
┌──────┐ ┌─────────┐ ┌───────────────┐
│ CLI │ │ Browser │ │ Roo Code Cloud│
└──┬───┘ └────┬────┘ └───────┬───────┘
│ │ │
│ Open auth URL │ │
│─────────────────>│ │
│ │ │
│ │ Authenticate │
│ │─────────────────────>│
│ │ │
│ │<─────────────────────│
│ │ Token via callback │
│<─────────────────│ │
│ │ │
│ Store token │ │
│ │ │
```

## Options

| Option | Description | Default |
| --------------------------------- | --------------------------------------------------------------------------------------- | ----------------------------- |
| `[workspace]` | Workspace path to operate in (positional argument) | Current directory |
| `-P, --prompt <prompt>` | The prompt/task to execute (optional in TUI mode) | None |
| `-e, --extension <path>` | Path to the extension bundle directory | Auto-detected |
| `-d, --debug` | Enable debug output (includes detailed debug information, prompts, paths, etc) | `false` |
| `-x, --exit-on-complete` | Exit the process when task completes (useful for testing) | `false` |
| `-y, --yes` | Non-interactive mode: auto-approve all actions | `false` |
| `-k, --api-key <key>` | API key for the LLM provider | From env var |
| `-p, --provider <provider>` | API provider (anthropic, openai, openrouter, etc.) | `openrouter` |
| `-m, --model <model>` | Model to use | `anthropic/claude-sonnet-4.5` |
| `-M, --mode <mode>` | Mode to start in (code, architect, ask, debug, etc.) | `code` |
| `-r, --reasoning-effort <effort>` | Reasoning effort level (unspecified, disabled, none, minimal, low, medium, high, xhigh) | `medium` |
| `--ephemeral` | Run without persisting state (uses temporary storage) | `false` |
| `--no-tui` | Disable TUI, use plain text output | `false` |

## Auth Commands

| Command | Description |
| ----------------- | ---------------------------------- |
| `roo auth login` | Authenticate with Roo Code Cloud |
| `roo auth logout` | Clear stored authentication token |
| `roo auth status` | Show current authentication status |

## Environment Variables

The CLI will look for API keys in environment variables if not provided via `--api-key`:

| Provider | Environment Variable |
| ------------- | -------------------- |
| anthropic | `ANTHROPIC_API_KEY` |
| openai | `OPENAI_API_KEY` |
| openrouter | `OPENROUTER_API_KEY` |
| google/gemini | `GOOGLE_API_KEY` |
| ... | ... |

**Authentication Environment Variables:**

| Variable | Description |
| ----------------- | -------------------------------------------------------------------- |
| `ROO_WEB_APP_URL` | Override the Roo Code Cloud URL (default: `https://app.roocode.com`) |

## Architecture

```
┌─────────────────┐
│ CLI Entry │
│ (index.ts) │
└────────┬────────┘
┌─────────────────┐
│ ExtensionHost │
│ (extension- │
│ host.ts) │
└────────┬────────┘
┌────┴────┐
│ │
▼ ▼
┌───────┐ ┌──────────┐
│vscode │ │Extension │
│-shim │ │ Bundle │
└───────┘ └──────────┘
```

## How It Works

1. **CLI Entry Point** (`index.ts`): Parses command line arguments and initializes the ExtensionHost

2. **ExtensionHost** (`extension-host.ts`):

- Creates a VSCode API mock using `@roo-code/vscode-shim`
- Intercepts `require('vscode')` to return the mock
- Loads and activates the extension bundle
- Manages bidirectional message flow

3. **Message Flow**:
- CLI → Extension: `emit("webviewMessage", {...})`
- Extension → CLI: `emit("extensionWebviewMessage", {...})`

## Development

```bash
# Watch mode for development
pnpm dev

# Run tests
pnpm test

# Type checking
pnpm check-types

# Linting
pnpm lint
```

## Releasing

To create a new release, execute the /cli-release slash command:

```bash
roo ~/Documents/Roo-Code -P "/cli-release" -y
```

The workflow will:

1. Bump the version
2. Update the CHANGELOG
3. Build the extension and CLI
4. Create a platform-specific tarball (for your current OS/architecture)
5. Test the install script
6. Create a GitHub release with the tarball attached
Loading
Loading