Skip to content

Commit 434f68e

Browse files
committed
Add OpenCode preset and guided install for npm-based built-ins
- Add OpenCode (opencode, npm: opencode-ai) to the built-in agent presets. - Enable a guided install with the official command for the npm-installable built-ins (Claude Code, Codex, Copilot, Gemini, OpenCode): when the command is not found, Super CLI offers to install it after explicit confirmation. - Grok, Kilo, and Antigravity use OS-specific shell installers and are left out of auto-install to avoid shipping a non-cross-platform command.
1 parent f0e8859 commit 434f68e

5 files changed

Lines changed: 47 additions & 6 deletions

File tree

CHANGELOG.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,14 @@
33
All notable changes to this project are documented here. The format is based on
44
[Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
55

6+
## [0.2.0]
7+
8+
- Added **OpenCode** to the built-in agent presets.
9+
- Built-in CLIs that install from npm (Claude Code, Codex, Copilot, Gemini, OpenCode) now offer a
10+
guided install with their official command when the command is not found. Grok, Kilo, and
11+
Antigravity use OS-specific shell installers and are not auto-offered; add a custom `installCommand`
12+
for your platform if you want one.
13+
614
## [0.1.0]
715

816
- Initial release.

README.md

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
[![CI](https://github.com/TheStreamCode/super-cli/actions/workflows/ci.yml/badge.svg)](https://github.com/TheStreamCode/super-cli/actions/workflows/ci.yml)
66

77
One VS Code extension to launch any coding agent CLI — **Claude Code, Codex, GitHub Copilot CLI,
8-
Gemini, Grok, Kilo, Antigravity, and your own** — from a single sidebar and a side terminal.
8+
Gemini, Grok, Kilo, Antigravity, OpenCode, and your own** — from a single sidebar and a side terminal.
99

1010
Works on Windows, macOS, and Linux, and across the VS Code family (VS Code, Cursor, Antigravity,
1111
Windsurf).
@@ -31,10 +31,13 @@ You can also open the Extensions view in VS Code (or Cursor, Antigravity, Windsu
3131
- **One launcher for every agent.** A **Super CLI** view in the activity bar lists all configured
3232
agents; click one to open it in a terminal beside your editor. A toolbar button and the
3333
**Super CLI: Launch Coding Agent** command open a quick pick of the same list.
34-
- **Built-in presets.** Claude Code, Codex, GitHub Copilot CLI, Gemini, Grok, Kilo, and Antigravity
35-
are available out of the box.
34+
- **Built-in presets.** Claude Code, Codex, GitHub Copilot CLI, Gemini, Grok, Kilo, Antigravity, and
35+
OpenCode are available out of the box.
3636
- **Add your own, no code required.** Define new agents in `settings.json`. The sidebar updates
3737
automatically.
38+
- **Guided install.** If a built-in CLI that installs from npm (Claude Code, Codex, Copilot, Gemini,
39+
OpenCode) isn't found, Super CLI offers to install it with its official command — after explicit
40+
confirmation.
3841
- **Native integrated terminal.** Each agent runs in a real VS Code terminal, inheriting your
3942
shell, `PATH`, and environment. No bundled emulator, no runtime dependencies.
4043

package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"displayName": "Super CLI",
44
"description": "One VS Code extension to launch any coding agent CLI (Claude Code, Codex, Copilot, Gemini, and your own) from a single side terminal.",
55
"publisher": "mikesoft",
6-
"version": "0.1.0",
6+
"version": "0.2.0",
77
"repository": {
88
"type": "git",
99
"url": "https://github.com/TheStreamCode/super-cli.git"
@@ -156,7 +156,7 @@
156156
"properties": {
157157
"id": {
158158
"type": "string",
159-
"description": "Unique identifier. Reuse a built-in id (claude, codex, copilot, gemini, grok, kilo, antigravity) to override that built-in."
159+
"description": "Unique identifier. Reuse a built-in id (claude, codex, copilot, gemini, grok, kilo, antigravity, opencode) to override that built-in."
160160
},
161161
"label": {
162162
"type": "string",
@@ -186,7 +186,7 @@
186186
"type": "boolean",
187187
"scope": "machine",
188188
"default": true,
189-
"description": "Include the built-in agent presets (Claude Code, Codex, Copilot, Gemini, Grok, Kilo, Antigravity) in the launcher."
189+
"description": "Include the built-in agent presets (Claude Code, Codex, Copilot, Gemini, Grok, Kilo, Antigravity, OpenCode) in the launcher."
190190
},
191191
"superCli.terminalLocation": {
192192
"type": "string",

src/agents.ts

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,25 +16,31 @@ export const BUILTIN_AGENTS: readonly Agent[] = [
1616
command: 'claude',
1717
icon: 'sparkle',
1818
installCommand: 'npm install -g @anthropic-ai/claude-code',
19+
autoInstall: true,
1920
},
2021
{
2122
id: 'codex',
2223
label: 'Codex CLI',
2324
command: 'codex',
2425
icon: 'rocket',
26+
installCommand: 'npm install -g @openai/codex',
27+
autoInstall: true,
2528
},
2629
{
2730
id: 'copilot',
2831
label: 'GitHub Copilot CLI',
2932
command: 'copilot',
3033
icon: 'github',
3134
installCommand: 'npm install -g @github/copilot',
35+
autoInstall: true,
3236
},
3337
{
3438
id: 'gemini',
3539
label: 'Gemini CLI',
3640
command: 'gemini',
3741
icon: 'star-full',
42+
installCommand: 'npm install -g @google/gemini-cli',
43+
autoInstall: true,
3844
},
3945
{
4046
id: 'grok',
@@ -54,6 +60,14 @@ export const BUILTIN_AGENTS: readonly Agent[] = [
5460
command: 'agy',
5561
icon: 'globe',
5662
},
63+
{
64+
id: 'opencode',
65+
label: 'OpenCode',
66+
command: 'opencode',
67+
icon: 'code',
68+
installCommand: 'npm install -g opencode-ai',
69+
autoInstall: true,
70+
},
5771
];
5872

5973
/** Returns true when a value is a usable agent definition (non-empty id and command). */

test/agents.test.js

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,3 +45,19 @@ test('resolveAgents skips entries without a usable id or command', () => {
4545

4646
assert.deepEqual(agents.map((agent) => agent.id), ['good']);
4747
});
48+
49+
test('OpenCode ships as a built-in preset', () => {
50+
const opencode = BUILTIN_AGENTS.find((agent) => agent.id === 'opencode');
51+
assert.ok(opencode);
52+
assert.equal(opencode.command, 'opencode');
53+
assert.equal(opencode.installCommand, 'npm install -g opencode-ai');
54+
});
55+
56+
test('npm-installable built-ins offer a guided install with their official command', () => {
57+
for (const id of ['claude', 'codex', 'copilot', 'gemini', 'opencode']) {
58+
const agent = BUILTIN_AGENTS.find((a) => a.id === id);
59+
assert.ok(agent, `expected built-in ${id}`);
60+
assert.match(agent.installCommand, /^npm install -g /);
61+
assert.equal(agent.autoInstall, true);
62+
}
63+
});

0 commit comments

Comments
 (0)