N/A This is the final npm -> pnpm migration step for the OSS repo. - Adds `editors/vscode` and `deploy/cloudflare` to `pnpm-workspace.yaml` so they use the root `packageManager: pnpm@11.15.1` and the shared `pnpm-lock.yaml`. - Removes the per-package `package-lock.json` files and deletes the now-obsolete `scripts/normalize_package_lock_registry.py` hook/script. - Merges the three remaining categories of build-script approvals into `pnpm-workspace.yaml` (`@vscode/vsce-sign`, `esbuild`, `keytar`, `sharp`, `workerd`) so `pnpm install` works at the workspace root. - Migrates VS Code and release workflows to `setup-pnpm`: - `.github/workflows/vscode-extension-release.yml` - `.github/workflows/vscode-release-pr.yml` - `.github/workflows/release-omnigent.yml` - Updates the lockfile regen workflows to refresh `pnpm-lock.yaml` instead of the old web-only `package-lock.json`: - `.github/workflows/oss-regenerate-and-smoke.yml` - `.github/workflows/oss-regen-on-comment.yml` - Updates `editors/vscode/README.md`, `editors/vscode/PUBLISHING.md`, and `deploy/cloudflare/README.md` to reference pnpm commands. - Removes the deprecated `.github/actions/setup-node` composite action. - `pnpm install --frozen-lockfile --filter omnigent-vscode` passes locally. - `pnpm install --frozen-lockfile --filter omnigent-cloudflare` passes locally. - `uv run pre-commit run --all-files` passes (after dropping the package-lock registry hook). - Inspected remaining `npm install` occurrences in workflows; the only survivors are transient agent CLI installs (`@anthropic-ai/claude-code`, `@openai/codex`) that are intentionally not tracked in the lockfile. N/A - [ ] Bug fix - [ ] Feature - [ ] UI / frontend change - [x] Refactor / chore - [ ] Docs - [ ] Test / CI - [ ] Breaking change - [ ] Unit tests added / updated - [ ] Integration tests added / updated - [ ] E2E tests added / updated - [x] Manual verification completed - [ ] Existing tests cover this change - [ ] Not applicable Verified the new workspace packages install from the frozen pnpm lockfile and that the pnpm-only lockfile regen scripts produce a valid lock. The VS Code workflow commands were checked against the package names/filters from `pnpm-workspace.yaml`. N/A Signed-off-by: Zeyi (Rice) Fan <zeyi.f@databricks.com>
2.8 KiB
Omnigent for VS Code
A minimal VS Code extension that opens your running local Omnigent server inside
the editor — an editor-beside pane that iframes the same UI you see at
http://127.0.0.1:6767. It is a thin client of the local server's existing HTTP API
(server/API.md); there is nothing new to run on the server side.
This is the first, deliberately small donation (tracking omnigent-ai/omnigent#1219): localhost discovery, the editor iframe pane, and the activity-bar / editor-title icons. Sessions, diffs, send-selection, and remote/embedded rendering are intentionally out of scope for now.
How it works
- On activation the extension discovers a locally running server via
~/.omnigent/local_server.pidand a/healthprobe (or usesomnigent.serverUrlwhen set to a localhost URL). - The Omnigent activity-bar view offers an Open Omnigent button. The
Omnigent: Open command (
omnigent.open) — also on the editor title bar and in the command palette — opens an editor-beside pane that frames the running server. - The iframe path is used for local servers only; a local server is loopback and needs no auth, so no token ever appears in the iframe URL.
Settings
| Setting | Default | Purpose |
|---|---|---|
omnigent.serverUrl |
"" |
Manual localhost server URL override (e.g. http://127.0.0.1:6767); empty = auto-discover. Non-localhost URLs are not supported in this build. |
Known limitation
On macOS, VS Code does not deliver Cmd+A/C/V keystrokes into a cross-origin iframe
inside a webview, so keyboard paste into the framed app's inputs does not work there.
This is an upstream VS Code issue, not fixable from the extension for the iframe render
path — see microsoft/vscode#129178 and microsoft/vscode#182642. (The on-page copy
buttons and navigator.clipboard paths still work.)
Build / test / package
pnpm install --frozen-lockfile
pnpm run type-check # tsc --noEmit
pnpm run test # vitest run
pnpm run build # esbuild -> dist/extension.js
pnpm run package # @vscode/vsce package -> omnigent-vscode-<version>.vsix
Install the resulting .vsix via the Extensions view → "Install from VSIX…". The
.vsix runtime is dist/extension.js + media/.
Layout
src/
├── extension.ts # activate()/deactivate() — wires discovery + panel + command + view
├── commands/openPanel.ts # the omnigent.open command
├── panel/ # EditorPanelController, host.ts (render), iframeHtml.ts, csp.ts
├── config/ # settings + localhost server-target resolution
└── discovery/ # local-server discovery (pidfile / health / liveness)
Licensed under Apache-2.0 (see LICENSE). Contributions require a DCO sign-off
(git commit -s), per the repository CONTRIBUTING.md.