dsh-vscode
DeepSeek Harness tool plugin: open files, folders, and diff views in the local Visual Studio Code (open_in_vscode tool), spawning Code.exe directly so the sandboxed shell cannot block it.
安装
$
npx -p @deepseek-ai/dsh dsh plugin --profile web add github:Hyna-hla/dsh-vscode说明文档
阅读完整 README ↗dsh-vscode
宿主工具插件:给 DSH 注册 open_in_vscode 工具,直接调用本地 Visual Studio Code。
- 打开文件或文件夹(相对路径基于当前会话工作区);
line/column跳转到指定位置(--goto file:line:col);diffPath打开两个文件的对比视图(--diff);wait: true时等待窗口关闭再返回(默认立即返回)。
之所以做成插件:DSH 的 pwsh 沙盒会拦截工作区外的可执行文件,模型自己敲 code xxx 不可靠;宿主插件直接 spawn Code.exe(stdio: ignore + detached),不受沙盒限制。
配置
- insert:
- id: dsh-vscode
name: dsh-vscode
config:
codeExe: '' # 留空自动探测;可指定 Code.exe 或 bin\code.cmd 路径
自动探测顺序:%LOCALAPPDATA%\Programs\Microsoft VS Code\Code.exe → %ProgramFiles% → %ProgramFiles(x86)% → PATH 上的 code.cmd(经 cmd.exe 启动)。
构建安装
pnpm install
pnpm build
.\scripts\install-to-profile.ps1 -Name dsh-vscode -SourceDir .
# 重启 DeepSeek Harness