Skip to main content
J

dsh-vscode-workspace

jamalesam93/dsh-vscode-workspace

Multi-root .code-workspace and .workspace support: round-trip JSONC editor, per-session sandbox grants, cross-root search tools, and Better Sidebar Multi-Root Explorer. Its HTTP routes have no DSH access check, so a web page open in your browser could call them.

Install

dsh plugin --profile web add github:jamalesam93/dsh-vscode-workspace

README

dsh-vscode-workspace

dsh-vscode-workspace icon

Native VS Code / Cursor / Antigravity IDE multi-root workspace (.code-workspace and .workspace) support for DeepSeek Harness (DSH 0.2.2+).

Features

  • Full .code-workspace & .workspace JSONC compatibility: Parses and round-trip edits files using Microsoft's jsonc-parser — comments (//, /* */), trailing commas, formatting, and IDE-specific sections (extensions, tasks, launch, npm.exclude, Cursor/Antigravity settings) are preserved.
  • Per-session multi-root sandbox grants: Automatically calls ctx.sandboxPolicy.registerWritableRoot(session, dir) for every secondary root in the active workspace, so DSH file tools (read, write, edit, patch) work across all roots.
  • KV-cache-friendly runtime context: Injects active workspace roots, aliases, and exclude settings via ctx.systemPrompt.context only when a multi-root workspace is active (zero token overhead on single-folder workspaces).
  • Cross-root agent tools: Registers workspace_info (roots + Git branch/dirty status + settings) and workspace_search (glob / grep across all roots honoring files.exclude and search.exclude).
  • Auto-discovery & live sync: Automatically detects .code-workspace / .workspace files inside your DSH workspaces and watches active files via fs.watch so edits made in VS Code, Cursor, or Antigravity IDE sync live into DSH.
  • Left-sidebar Workspaces panel: Dedicated Workspaces nav entry (sidebar.panellist) to open any .code-workspace / .workspace via a cross-platform native file dialog (Windows / macOS / Linux + pure-web browser fallback), create new workspaces, and manage active bindings.
  • Optional Better Sidebar integration (zero conflicts if dsh-better-sidebar is installed; works cleanly without it too):
    • Multi-Root Explorer tab: Unified collapsible tree across all roots with Git branch/dirty chips, cross-root file/text search, files.exclude toggle, create/rename/delete, @path chat citations, and click-to-open directly in Better Sidebar's native CodeMirror editor.
    • Visual .code-workspace / .workspace file viewer: Add/remove/reorder/rename roots, edit files.exclude, inspect preserved IDE settings, and toggle Raw JSONC.
    • Custom file icon & context menu actions: "Open as Multi-Root Workspace" on .code-workspace/.workspace files and "Add Folder to Active Workspace" on folders.

Install

From GitHub Release (Prebuilt — No Build Step Required)

# DSH Desktop:
dsh plugin --profile desktop add https://github.com/jamalesam93/dsh-vscode-workspace/releases/download/v0.1.0/dsh-vscode-workspace-0.1.0.tgz

# DSH Web:
dsh plugin --profile web add https://github.com/jamalesam93/dsh-vscode-workspace/releases/download/v0.1.0/dsh-vscode-workspace-0.1.0.tgz

Local Development

npm install
npm run check
dsh plugin --profile desktop add link:"/path/to/dsh-vscode-workspace"

Windows Sandbox Note

On Windows, DSH's ctx.sandboxPolicy.registerWritableRoot pre-authorizes all harness file tools (read, write, edit, patch) across every workspace root. Sandboxed shell commands (pwsh/bash) writing outside the primary cwd root may still prompt for escalation unless the session uses danger-full-access or an explicit allow rule.

License

MIT

Related plugins