DimAgent for VS Code
Launch the dimcode AI agent TUI directly inside VS Code, with workspace context awareness.
Features
- 🖥 Open TUI — One-click terminal with
dim in a split editor pane
- 📄 Context-aware launch — Auto-inject focused file path and selected code
- ▶ One-shot prompt — Run
dim exec with editor context auto-appended
- 🔧 CLI command runner — Quick access to auth, sessions, providers, MCP
Requirements
- dimcode CLI installed and available on PATH
- VS Code 1.87+
Quick Start
- Install the extension
- Click the DimAgent icon in the editor toolbar (top-right) or activity bar
- The dim TUI opens in a split pane next to your code
Usage
| Action |
How |
| Open TUI |
Click toolbar icon, or Cmd+Shift+P → DimAgent: Open TUI |
| Open with context |
DimAgent: Open TUI with Context — injects focused file + selection |
| Run prompt |
DimAgent: Run Prompt — auto-includes active file and selected code |
| CLI commands |
DimAgent: Run CLI Command — quick pick for auth, sessions, providers, MCP |
Keyboard Shortcuts
| Shortcut |
Command |
Cmd+Shift+Alt+D |
Open TUI |
Cmd+Shift+Alt+E |
Open TUI with Context |
Configuration
| Setting |
Type |
Default |
Description |
dimagent.cli.path |
string |
dim |
Path to the dim binary |
dimagent.cli.defaultArgs |
string[] |
[] |
Extra CLI arguments |
How It Works
The extension spawns dim in a VS Code terminal placed in the editor area via ViewColumn.Beside. When using context-aware commands, it resolves:
- Workspace root → terminal
cwd
- Active file → injected as
DIMCODE_ACTIVE_FILE env var
- Selected text → injected as
DIMCODE_ACTIVE_SELECTION env var
For Run Prompt, file path and selection are also prepended to the prompt text sent to dim exec.
| |