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
28 changes: 15 additions & 13 deletions DIVERGENCES.md

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion packages/opencode/src/ide/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ export async function install(ide: (typeof SUPPORTED_IDES)[number]["name"]) {
const cmd = SUPPORTED_IDES.find((i) => i.name === ide)?.cmd
if (!cmd) throw new Error(`Unknown IDE: ${ide}`)

const p = await Process.run([cmd, "--install-extension", "sst-dev.opencode"], {
const p = await Process.run([cmd, "--install-extension", "codev.codev-code"], {
nothrow: true,
})
const stdout = p.stdout.toString()
Expand Down
9 changes: 8 additions & 1 deletion packages/web/src/content/docs/es/ide.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,14 @@ Si, por otro lado, desea utilizar su propio IDE cuando ejecuta `/editor` o `/exp

### Instalación manual

Busque **OpenCode** en Extension Marketplace y haga clic en **Instalar**.
La extensión no está publicada en Extension Marketplace. Compile el `.vsix` desde una copia del repositorio e instálelo manualmente:

```bash
cd sdks/vscode
bun install
bun run vsix
code --install-extension dist/codev-code-<version>.vsix
```

---

Expand Down
9 changes: 8 additions & 1 deletion packages/web/src/content/docs/ide.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,14 @@ If on the other hand you want to use your own IDE when you run `/editor` or `/ex

### Manual Install

Search for **OpenCode** in the Extension Marketplace and click **Install**.
The extension is not listed on the Extension Marketplace. Build the `.vsix` from a checkout and install it manually:

```bash
cd sdks/vscode
bun install
bun run vsix
code --install-extension dist/codev-code-<version>.vsix
```

---

Expand Down
10 changes: 5 additions & 5 deletions sdks/vscode/README.md
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
# CoDev Code VS Code Extension

A Visual Studio Code extension that integrates [opencode](https://opencode.ai) directly into your development workflow.
A Visual Studio Code extension that integrates [CoDev Code](https://github.com/quickbeard/codev-code) (the `codev` CLI) directly into your development workflow.

## Prerequisites

This extension requires the [opencode CLI](https://opencode.ai) to be installed on your system. Visit [opencode.ai](https://opencode.ai) for installation instructions.
This extension requires the `codev` CLI to be installed on your system: `npm install -g codev-code`.

## Features

- **Quick Launch**: Use `Cmd+Esc` (Mac) or `Ctrl+Esc` (Windows/Linux) to open opencode in a split terminal view, or focus an existing terminal session if one is already running.
- **New Session**: Use `Cmd+Shift+Esc` (Mac) or `Ctrl+Shift+Esc` (Windows/Linux) to start a new opencode terminal session, even if one is already open. You can also click the opencode button in the UI.
- **Context Awareness**: Automatically share your current selection or tab with opencode.
- **Quick Launch**: Use `Cmd+Esc` (Mac) or `Ctrl+Esc` (Windows/Linux) to open CoDev Code in a split terminal view, or focus an existing terminal session if one is already running.
- **New Session**: Use `Cmd+Shift+Esc` (Mac) or `Ctrl+Shift+Esc` (Windows/Linux) to start a new CoDev Code terminal session, even if one is already open. You can also click the CoDev Code button in the UI.
- **Context Awareness**: Automatically share your current selection or tab with CoDev Code.
- **File Reference Shortcuts**: Use `Cmd+Option+K` (Mac) or `Alt+Ctrl+K` (Linux/Windows) to insert file references. For example, `@File#L37-42`.

## Support
Expand Down
502 changes: 501 additions & 1 deletion sdks/vscode/bun.lock

Large diffs are not rendered by default.

28 changes: 15 additions & 13 deletions sdks/vscode/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,54 +25,54 @@
"contributes": {
"commands": [
{
"command": "opencode.openTerminal",
"title": "Open opencode",
"command": "codev.openTerminal",
"title": "Open CoDev Code",
"icon": {
"light": "images/button-dark.svg",
"dark": "images/button-light.svg"
}
},
{
"command": "opencode.openNewTerminal",
"title": "Open opencode in new tab",
"command": "codev.openNewTerminal",
"title": "Open CoDev Code in new tab",
"icon": {
"light": "images/button-dark.svg",
"dark": "images/button-light.svg"
}
},
{
"command": "opencode.addFilepathToTerminal",
"command": "codev.addFilepathToTerminal",
"title": "Add Filepath to Terminal"
}
],
"menus": {
"editor/title": [
{
"command": "opencode.openNewTerminal",
"command": "codev.openNewTerminal",
"group": "navigation"
}
]
},
"keybindings": [
{
"command": "opencode.openTerminal",
"title": "Run opencode",
"command": "codev.openTerminal",
"title": "Run CoDev Code",
"key": "cmd+escape",
"mac": "cmd+escape",
"win": "ctrl+escape",
"linux": "ctrl+escape"
},
{
"command": "opencode.openNewTerminal",
"title": "Run opencode",
"command": "codev.openNewTerminal",
"title": "Run CoDev Code",
"key": "cmd+shift+escape",
"mac": "cmd+shift+escape",
"win": "ctrl+shift+escape",
"linux": "ctrl+shift+escape"
},
{
"command": "opencode.addFilepathToTerminal",
"title": "opencode: Insert At-Mentioned",
"command": "codev.addFilepathToTerminal",
"title": "CoDev Code: Insert At-Mentioned",
"key": "cmd+alt+k",
"mac": "cmd+alt+k",
"win": "ctrl+alt+K",
Expand All @@ -86,6 +86,7 @@
"watch:esbuild": "node esbuild.js --watch",
"watch:tsc": "tsc --noEmit --watch --project tsconfig.json",
"package": "bun run check-types && bun run lint && node esbuild.js --production",
"vsix": "vsce package --no-dependencies --skip-license -o dist/",
"compile-tests": "tsc -p . --outDir out",
"watch-tests": "tsc -p . -w --outDir out",
"pretest": "bun run compile-tests && bun run compile && bun run lint",
Expand All @@ -103,6 +104,7 @@
"esbuild": "^0.25.3",
"typescript": "^5.8.3",
"@vscode/test-cli": "^0.0.11",
"@vscode/test-electron": "^2.5.2"
"@vscode/test-electron": "^2.5.2",
"@vscode/vsce": "^3.6.0"
}
}
12 changes: 6 additions & 6 deletions sdks/vscode/src/extension.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,15 @@ export function deactivate() {}

import * as vscode from "vscode"

const TERMINAL_NAME = "opencode"
const TERMINAL_NAME = "codev"

export function activate(context: vscode.ExtensionContext) {
const openNewTerminalDisposable = vscode.commands.registerCommand("opencode.openNewTerminal", async () => {
const openNewTerminalDisposable = vscode.commands.registerCommand("codev.openNewTerminal", async () => {
await openTerminal()
})

const openTerminalDisposable = vscode.commands.registerCommand("opencode.openTerminal", async () => {
// An opencode terminal already exists => focus it
const openTerminalDisposable = vscode.commands.registerCommand("codev.openTerminal", async () => {
// A codev terminal already exists => focus it
const existingTerminal = vscode.window.terminals.find((t) => t.name === TERMINAL_NAME)
if (existingTerminal) {
existingTerminal.show()
Expand All @@ -21,7 +21,7 @@ export function activate(context: vscode.ExtensionContext) {
await openTerminal()
})

let addFilepathDisposable = vscode.commands.registerCommand("opencode.addFilepathToTerminal", async () => {
let addFilepathDisposable = vscode.commands.registerCommand("codev.addFilepathToTerminal", async () => {
const fileRef = getActiveFile()
if (!fileRef) {
return
Expand Down Expand Up @@ -62,7 +62,7 @@ export function activate(context: vscode.ExtensionContext) {
})

terminal.show()
terminal.sendText(`opencode --port ${port}`)
terminal.sendText(`codev --port ${port}`)

const fileRef = getActiveFile()
if (!fileRef) {
Expand Down
Loading