nightosong/gord-dsh-worktree 预览 preview

nightosong/gord-dsh-worktree

Git worktrees for DeepSeek Harness — isolate parallel work in its own directory and branch. Ships Fast mode (快速模式).

Project Overview项目介绍

gord-dsh-worktree is a native plugin built specifically for DeepSeek Harness (DSH), packaging git worktree management as an integrated layer of the host's bundle stack. Installation is performed through the official dsh plugin --profile web add github:nightosong/gord-dsh-worktree command, and the package's manifest declares dsh.bundle.patch, so the CLI mounts it onto the profile's bundle stack on its own. A dsh web restart (or reload once the bundle is already on the stack) then surfaces five agent-callable tools — worktree_list, worktree_create, worktree_status, worktree_remove, and worktree_prune — alongside a Worktrees section in Settings.

The plugin targets DSH users who need to keep parallel investigations of the same repository from polluting each other. From the New Session row, a working-location picker offers exactly two choices: stay in the Current worktree, or pick "New worktree" and have an isolated checkout plus a freshly cut branch created and a session opened inside it in one atomic step; the right sidebar's Changes tab then shows uncommitted diffs scoped to that session's own directory. Settings → Worktrees centralises the live worktree list, archive management (per-row Unarchive, single delete, Delete all), and a Create form, while a double-click on a sidebar row renames a session without a menu. A worktree made mid-conversation does not adopt itself as a workspace, which avoids adding unsolicited sidebar entries.

It depends on DSH 0.1.5-rc.1 or newer and is plain ESM with no build step: lib/index.js is the host half, lib/client.js loads through window.__ModuleLoader__, and lib/service.js plus lib/worktree.js hold the git logic they share. Local checkouts must symlink @deepseek-ai/schemastery, dsh-tools, dsh-settings, and cordis into node_modules/@deepseek-ai/, since the host half resolves from its own directory while DSH peers resolve from the profile; GitHub or npm installs need none of this. The main worktree cannot be removed, dirty worktrees require force (because --force would also drop untracked files), locked worktrees are reported rather than silently unlocked, branch names pass git check-ref-format, paths are passed as positional git arguments to avoid flag injection, and the HTTP mutating route accepts only same-origin and loopback callers. Deleting archived sessions is the sole irreversible operation, guarded by an explicit confirmation and refused for any session still running. The project ships under the MIT license, with npm test running both smoke suites (host-side against a throwaway git repo, client-side against a minimal React runtime) and no test framework to install.

gord-dsh-worktree 是面向 DeepSeek Harness(DSH)的一款原生 worktree 插件。它通过 dsh plugin add 命令安装,并在 manifest 中声明 dsh.bundle.patch,由 CLI 自动挂载到 web 配置的 bundle 栈中;安装后重启 dsh web 即可在 Settings → Worktrees 中看到新增的五个 agent 工具:worktree_list、worktree_create、worktree_status、worktree_remove、worktree_prune。

该插件面向需要在同一仓库内并行开展多分支任务的 DSH 用户。典型流程是在 New Session 行的工作位置选择器中挑选 Current worktree 或 New worktree,前者继续在当前目录启动会话,后者一次性创建隔离目录、新分支并把会话开在其中。右侧 Changes 侧栏可查看该工作目录的未提交 diff,Settings 页面集中管理本地 worktree 列表与归档会话,并提供 Unarchive、单条删除与一键全部删除等动作,工作目录的会话还支持双击重命名。

插件依赖 dsh 0.1.5-rc.1 及以上版本,主分支 worktree 不可删除、脏工作目录需 force 才能移除、被锁定的 worktree 仅报告不解锁,分支名通过 git check-ref-format 校验、路径仅作位置参数传入以防被解释为 flag。HTTP 变更接口仅接受同源与回环调用,不可作为远程 API;归档会话删除是唯一不可撤销的操作,需显式确认且拒绝作用于仍在运行的会话。源码为纯 ESM、无构建步骤,本地开发需将 schemastery、dsh-tools、dsh-settings、cordis 等 @deepseek-ai/* 软链进 node_modules;项目以 MIT 协议发布。

Pre-install check安装前体检Compatibility · Security兼容性 · 安全性 1 warning1 项注意
  • Only 2 stars - very few users, little community feedback星标只有 2,几乎没人在用,遇到问题缺少社区反馈
DSH walks through these 9 checksDSH 会逐条核对这 9 项

Compatibility兼容性

  • DSH, Node, OS and profile requirementsDSH 版本 / Node 版本 / 操作系统 / profile 是否满足要求
  • External dependencies and runtimes (Electron / Python / Docker, ...)外部依赖与运行时(Electron / Python / Docker 等)是否齐备
  • Conflicts with installed plugins: command names, skill / tool names, ports, duplicate MCP registration与已装插件是否冲突:命令名、skill / tool 重名、端口占用、重复 MCP 注册

Security安全性

  • Repo matches the facts registered here; archived or abandoned?仓库是否与页面登记一致,是否归档或长期停更
  • Safety of preinstall / install / postinstall and install.sh / setup.ps1preinstall / install / postinstall 与 install.sh、setup.ps1 是否安全
  • curl|bash, download-then-execute, obfuscation, unrelated domains → stop immediatelycurl|bash、下载即执行、混淆代码、无关域名 → 立刻停止
  • Typosquatting or unmaintained packages among the new dependencies新增依赖里有没有 typosquatting 或无人维护的包
  • Requested permissions vs. what the feature actually needs申请了哪些权限、是否超出功能所需(filesystem / network / shell / clipboard)
  • Any sudo / admin requirement, plus uninstall and rollback是否要求 sudo / 管理员权限,以及卸载与回滚方式

Anything uncertain must be marked unknown with a note on how to confirm it. This site's signal screen is a static snapshot, not a security audit.拿不准的必须标「未知」并说明要我怎么确认。本站的信号筛查是静态快照,不能替代安全审计。

Or use CLI install (for developers)或使用命令行安装(适合开发者)

CLI Install命令行安装

dsh plugin --profile web add github:nightosong/gord-dsh-worktree

把 nightosong/gord-dsh-worktree 加入你的 DSH 配置(web profile)即可启用。

READMEREADME

gord-dsh-worktree

Git worktree management for DeepSeek Harness: run parallel work in its own directory and branch. Ships Fast mode (快速模式) and two opt-in patches.

中文说明 · Long-form notes

The worktree selector on the New Session row, open, showing the current worktree and a new one The Worktrees settings page: the worktree list and the archived sessions card

What it does

  • Creates worktrees — an isolated checkout and branch in one atomic command, from the agent or from Settings → Worktrees. They live outside the project ($DSH_HOME/worktree/ by default), so a checkout never shows up in its own project's diffs.
  • Starts a session in one — the New Session row has a working-location picker: stay where you are, or create a worktree and open the session inside it.
  • Shows the diff — the sidebar's Changes tab lists the session's changed files and the selected file's patch.
  • Manages archived sessions — Settings → Worktrees lists every archived session with its id, title, project and log size, each row with Unarchive and a delete icon, plus Delete all.
  • Renames on double-click — rename a session from its sidebar row, without the menu.
  • Fast mode — a slim agent preset that ships with the plugin.
  • Concurrent read-only tool calls — opt-in patch for bash, glob and grep.

Install

dsh plugin --profile web add github:nightosong/gord-dsh-worktree

Restart dsh web, then open Settings → Worktrees. Nothing else to edit: the package declares its own bundle patch, which also declares the fast preset. Coming from the old name (dsh-worktree), remove that one and add this one.

The concurrency patch is the only opt-in step, because it edits core tool packages rather than the composition:

cd /path/to/gord-dsh-worktree
npm run patch:concurrency     # --check to inspect first, --revert to undo

It is idempotent — run it again after a DSH upgrade — and needs a dsh web restart.

Needs dsh >=0.1.5-rc.1 <0.2.0. Fast mode and the concurrency patch need 0.1.7 or newer; where the sidebar nesting is already native, the patch reports native and changes nothing.

Showing the opening section of the README — the full document lives in the repository以上为 README 开头摘要,完整文档在仓库内 · View the full README on GitHub →在 GitHub 查看完整 README →

← 上一个 Prev dsh-memory-manager 下一个 Next agent-memory-bridge →