@dsh-electron/dsh-plugin-multi-root-workspace 0.1.5 → 0.1.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.en.md +13 -1
- package/CHANGELOG.md +13 -1
- package/README.en.md +12 -10
- package/README.md +11 -11
- package/cordis.patch.yml +4 -0
- package/lib/client.js +320 -18
- package/lib/client.js.map +1 -1
- package/lib/{command-DyOWujPo.js → command-CTdNvwt1.js} +107 -6
- package/lib/command.js +1 -1
- package/lib/{compat-82Y27Iom.js → compat-B6ZqbQBy.js} +21 -3
- package/lib/compat.js +1 -1
- package/lib/index.js +5 -5
- package/lib/{instructions-Cn1Jj5Xi.js → instructions-DfzN-wVf.js} +106 -26
- package/lib/instructions.js +1 -1
- package/lib/lsp.js +38 -0
- package/lib/method-wrapper-Zc-JlDP3.js +51 -0
- package/lib/sandbox-BRXl_FpF.js +132 -0
- package/lib/sandbox.js +1 -1
- package/lib/scope.js +12 -6
- package/lib/session-directory-BLOstut1.js +9 -0
- package/lib/tool-context-CpgIFcCB.js +6 -0
- package/lib/types/client/RootFileTree.d.ts +12 -0
- package/lib/types/client/WorkspaceFoldersAction.d.ts +3 -0
- package/lib/types/client/index.d.ts +13 -2
- package/lib/types/client/locales.d.ts +14 -0
- package/lib/types/client/styles.d.ts +1 -1
- package/lib/types/compat/client-session.d.ts +2 -0
- package/lib/types/compat/dsh-version.d.ts +5 -3
- package/lib/types/compat/instruction-overlap.d.ts +7 -0
- package/lib/types/compat/session-directory.d.ts +4 -0
- package/lib/types/compat/tool-context.d.ts +9 -0
- package/lib/types/compat/workspace-files.d.ts +5 -0
- package/lib/types/contract.d.ts +24 -5
- package/lib/types/index.d.ts +2 -2
- package/lib/types/lsp.d.ts +4 -0
- package/lib/types/method-wrapper.d.ts +2 -0
- package/lib/types/panel-files.d.ts +3 -0
- package/lib/types/sandbox.d.ts +2 -11
- package/lib/types/scope.d.ts +3 -0
- package/lib/types/windows-profile.d.ts +13 -0
- package/lib/types/windows-runner.d.ts +1 -0
- package/lib/types/workspace-files.d.ts +4 -0
- package/lib/types/workspace-routing.d.ts +11 -0
- package/lib/{sandbox-D8Fw95FM.js → windows-profile-CiFsFYIV.js} +64 -138
- package/lib/windows-runner.js +68 -0
- package/lib/workspace-files.js +68 -0
- package/package.json +90 -47
package/CHANGELOG.en.md
CHANGED
|
@@ -8,6 +8,17 @@ This file records the user-visible changes of every **released** version.
|
|
|
8
8
|
- For installation sources, the supported upstream runtimes, and known limitations, see the [README](./README.en.md).
|
|
9
9
|
- The evidence, numbering, and release state of each version live in the [roadmap progress ledger](./docs/plans/active/2026-09-12-multi-root-workspace.md#进度总账). The body of each GitHub Release is generated from the commit history by `scripts/release-notes.mjs` and is the complete raw list behind this file.
|
|
10
10
|
|
|
11
|
+
## [0.1.6] - 2026-10-11
|
|
12
|
+
|
|
13
|
+
### Added
|
|
14
|
+
|
|
15
|
+
- Exact-version support for DSH `0.2.1-alpha.1` and `0.2.1-alpha.2`. Session origin is separated from the dynamic working directory, so changing cwd does not change registry ownership or authorized roots. Adds Worktree management, additional-root LSP routing, Windows kernel-enforced multi-root access, and additional-root file browsing and preview in Workspace Folders.
|
|
16
|
+
- Additional-root instructions are restored and re-delivered after cwd changes when still applicable.
|
|
17
|
+
|
|
18
|
+
### Changed
|
|
19
|
+
|
|
20
|
+
- Additional-root file trees and LSP routing are isolated per root; Worktree operations do not mutate root-registry authorization.
|
|
21
|
+
|
|
11
22
|
## [0.1.5] - 2026-09-30
|
|
12
23
|
|
|
13
24
|
### Added
|
|
@@ -103,7 +114,8 @@ The first release: the three MVP milestones (M1–M3).
|
|
|
103
114
|
|
|
104
115
|
- All eight findings of the pre-release external review (three of them release-blocking) are fixed, each with a regression test: a registered directory replaced by a symlink transplanting its authority (which introduced `recordedPath` — **re-resolving a path is not re-authorizing it**), concurrent registry mutations losing a write or reviving a revoked grant (per-primary-root mutations are serialized), a refresh not re-checking directories, a typed path being overwritten by the directory picker, the `reveal` response contract and failure code, duplicate ids not validated, the primary root missing from nesting validation, and CI testing before building.
|
|
105
116
|
|
|
106
|
-
[Unreleased]: https://github.com/cherrchen/dsh-plugin-multi-root-workspace/compare/v0.1.
|
|
117
|
+
[Unreleased]: https://github.com/cherrchen/dsh-plugin-multi-root-workspace/compare/v0.1.6...HEAD
|
|
118
|
+
[0.1.6]: https://github.com/cherrchen/dsh-plugin-multi-root-workspace/compare/v0.1.5...v0.1.6
|
|
107
119
|
[0.1.5]: https://github.com/cherrchen/dsh-plugin-multi-root-workspace/compare/v0.1.4...v0.1.5
|
|
108
120
|
[0.1.4]: https://github.com/cherrchen/dsh-plugin-multi-root-workspace/compare/v0.1.3...v0.1.4
|
|
109
121
|
[0.1.3]: https://github.com/cherrchen/dsh-plugin-multi-root-workspace/compare/v0.1.2...v0.1.3
|
package/CHANGELOG.md
CHANGED
|
@@ -8,6 +8,17 @@ English: [CHANGELOG.en.md](./CHANGELOG.en.md)
|
|
|
8
8
|
- 安装方式、受支持的上游运行时与已知限制见 [README](./README.md)。
|
|
9
9
|
- 每个版本的实施证据、编号口径与发布状态见[路线图 §进度总账](./docs/plans/active/2026-09-12-multi-root-workspace.md#进度总账);GitHub Release 的正文由 `scripts/release-notes.mjs` 从 commit 历史生成,是本文件之外的完整原始清单。
|
|
10
10
|
|
|
11
|
+
## [0.1.6] - 2026-10-11
|
|
12
|
+
|
|
13
|
+
### Added
|
|
14
|
+
|
|
15
|
+
- 精确支持 DSH `0.2.1-alpha.1` 与 `0.2.1-alpha.2`。动态 working directory 与 Session origin 分离:cwd 切换不改变注册表归属或授权根;新增 Worktree 管理、附加根 LSP 路由、Windows 内核级多根,以及 Workspace Folders 附加根文件浏览与预览。
|
|
16
|
+
- 附加根说明文件的 cwd 切换恢复与补发行为,避免上游撤回后遗漏仍有效的说明。
|
|
17
|
+
|
|
18
|
+
### Changed
|
|
19
|
+
|
|
20
|
+
- 附加根文件树与 LSP 按根隔离;Worktree 操作不改变根注册表授权。
|
|
21
|
+
|
|
11
22
|
## [0.1.5] - 2026-09-30
|
|
12
23
|
|
|
13
24
|
### Added
|
|
@@ -103,7 +114,8 @@ English: [CHANGELOG.en.md](./CHANGELOG.en.md)
|
|
|
103
114
|
|
|
104
115
|
- 发布前外部评审提出的 8 项发现(其中 3 项发布阻断)全部修复,每项各带一个回归测试:登记目录被替换为符号链接后授权转移(引入 `recordedPath`,**重新解析路径不等于重新授权**)、并发修改注册表丢写或复活已撤销的授权(每个主根的变更串行)、刷新不重新检查目录、手输路径被目录选择器覆盖、`reveal` 的应答契约与失败码、重复 id 未校验、主根未纳入嵌套校验、CI 先测后构建。
|
|
105
116
|
|
|
106
|
-
[Unreleased]: https://github.com/cherrchen/dsh-plugin-multi-root-workspace/compare/v0.1.
|
|
117
|
+
[Unreleased]: https://github.com/cherrchen/dsh-plugin-multi-root-workspace/compare/v0.1.6...HEAD
|
|
118
|
+
[0.1.6]: https://github.com/cherrchen/dsh-plugin-multi-root-workspace/compare/v0.1.5...v0.1.6
|
|
107
119
|
[0.1.5]: https://github.com/cherrchen/dsh-plugin-multi-root-workspace/compare/v0.1.4...v0.1.5
|
|
108
120
|
[0.1.4]: https://github.com/cherrchen/dsh-plugin-multi-root-workspace/compare/v0.1.3...v0.1.4
|
|
109
121
|
[0.1.3]: https://github.com/cherrchen/dsh-plugin-multi-root-workspace/compare/v0.1.2...v0.1.3
|
package/README.en.md
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
|
|
7
7
|
An out-of-tree plugin bundle for DSH (DeepSeek Harness) that widens the Workspace write scope from a single canonical directory to "**one primary root + N additional roots**" — **without modifying any package in the upstream repository**.
|
|
8
8
|
|
|
9
|
-
The problem it solves: a real development project is usually several independent Git repositories, while DSH natively treats only the session
|
|
9
|
+
The problem it solves: a real development project is usually several independent Git repositories, while DSH natively treats only the session origin as the writable root, so working across repositories means juggling sessions.
|
|
10
10
|
|
|
11
11
|
Three things make this plugin worth looking at:
|
|
12
12
|
|
|
@@ -24,7 +24,7 @@ Three things make this plugin worth looking at:
|
|
|
24
24
|
|
|
25
25
|
**Done and released: `v0.1.4`** — with the `v0.1.3` contract unchanged, the supported upstream runtimes grow to `0.1.7-rc.2` (same shapes as `0.1.7-rc.1`, no new adapter branch; cordis stays at `~4.0.4`). See the [CHANGELOG](./CHANGELOG.en.md).
|
|
26
26
|
|
|
27
|
-
|
|
27
|
+
**`v0.1.5` is released**. This development branch contains unreleased support for DSH `0.2.1-alpha.1` / `0.2.1-alpha.2`, separation of dynamic cwd from Session origin, and LSP, Windows ACL, additional-root file browsing, and Worktree capabilities. These changes are proposed for `v0.1.6`; see the [roadmap ledger](./docs/plans/active/2026-09-12-multi-root-workspace.md) for release status.
|
|
28
28
|
|
|
29
29
|
The single source of truth for progress, numbering, and release state is the [roadmap progress ledger](./docs/plans/active/2026-09-12-multi-root-workspace.md#进度总账) (M1–M4 are the MVP milestone numbers, H1–H4 are the `v0.1.1` batch numbers, and H1 is M4); per-item evidence lives in the [completed plans](./docs/plans/README.md), and the user-visible changes of each version are in the [CHANGELOG](./CHANGELOG.en.md).
|
|
30
30
|
|
|
@@ -47,13 +47,13 @@ The agent can now read, write, and run bash in that directory, with the same rig
|
|
|
47
47
|
|
|
48
48
|
## Requirements
|
|
49
49
|
|
|
50
|
-
- **Using a plugin built from this checkout**: you need a *supported* DSH runtime — currently **`0.1.5-rc.2`, `0.1.6-alpha.1`, `0.1.6-alpha.2`, `0.1.7-alpha.1`, `0.1.7-alpha.2`, `0.1.7-rc.1`, `0.1.7-rc.2`, `0.2.0-rc.1`,
|
|
50
|
+
- **Using a plugin built from this checkout**: you need a *supported* DSH runtime — currently **`0.1.5-rc.2`, `0.1.6-alpha.1`, `0.1.6-alpha.2`, `0.1.7-alpha.1`, `0.1.7-alpha.2`, `0.1.7-rc.1`, `0.1.7-rc.2`, `0.2.0-rc.1`, `0.2.0-rc.2`, `0.2.1-alpha.1`, and `0.2.1-alpha.2`**, and nothing else will install or run (see below). `dsh plugin` installs the package into the matching profile, and no local Node toolchain is required
|
|
51
51
|
- **Building from source / contributing**: **Node.js** `^22.19.0 || >=24` (pinned by the repository's `engines`), **Git**, and **pnpm 11** (`packageManager` pins `pnpm@11.25.0`; corepack recommended)
|
|
52
|
-
- **DSH runtime**: the dev pin is exactly `0.2.
|
|
53
|
-
- **Platforms**:
|
|
52
|
+
- **DSH runtime**: the dev pin is exactly `0.2.1-alpha.2`, the baseline among the supported releases; the upgrade procedure lives in the [development workflow](./docs/development/plugin-development-workflow.md)
|
|
53
|
+
- **Platforms**: macOS Seatbelt and Linux bwrap/Landlock; the development branch also implements a Windows root-set ACL runner. Platform validation is recorded in the [roadmap](./docs/plans/active/2026-09-12-multi-root-workspace.md#b1b3第二期-p12026-10-02).
|
|
54
54
|
- Running the smoke tests needs **no model credentials**: the e2e model turns are served by an inline scripted model endpoint
|
|
55
55
|
|
|
56
|
-
**The supported DSH versions are an exact list, not a range.** This plugin replaces `ctx.fs` and `ctx.sandbox` — the security boundary itself — and it recognizes kernel sandbox dialects from argv shapes measured against specific upstream releases. So `peerDependencies` names only the releases that have actually been through the full verification, and startup checks again: if the host's release is not on the list, or several `@deepseek-ai/dsh-*` packages disagree about which release they are, the fs / sandbox / registry / instructions rows **do not start**, the composition degrades to "this plugin is not installed", and one explanatory line is logged. To diagnose, see [troubleshooting: unsupported DSH release](./docs/troubleshooting/unsupported-dsh-release.md); for the reasoning, [ADR-0009](./docs/decisions/ADR-0009-dsh-compat-contract.md).
|
|
56
|
+
**The supported DSH versions are an exact list, not a range.** This plugin replaces `ctx.fs` and `ctx.sandbox` — the security boundary itself — and it recognizes kernel sandbox dialects from argv shapes measured against specific upstream releases. So `peerDependencies` names only the releases that have actually been through the full verification, and startup checks again: if the host's release is not on the list, or several `@deepseek-ai/dsh-*` packages disagree about which release they are, the fs / sandbox / registry / instructions / lsp / workspace-files rows **do not start**, the composition degrades to "this plugin is not installed", and one explanatory line is logged. To diagnose, see [troubleshooting: unsupported DSH release](./docs/troubleshooting/unsupported-dsh-release.md); for the reasoning, [ADR-0009](./docs/decisions/ADR-0009-dsh-compat-contract.md).
|
|
57
57
|
|
|
58
58
|
## Installation
|
|
59
59
|
|
|
@@ -146,7 +146,7 @@ dsh plugin --profile web add "$PWD"
|
|
|
146
146
|
dsh --profile web --dump-config
|
|
147
147
|
```
|
|
148
148
|
|
|
149
|
-
Expected: **only** the `fs-sandbox` and `sandbox` rows are replaced by the plugin's `multi-root-fs` / `multi-root-sandbox`, with
|
|
149
|
+
Expected: **only** the `fs-sandbox` and `sandbox` rows are replaced by the plugin's `multi-root-fs` / `multi-root-sandbox`, with ten rows inserted (`multi-root-compat` / `fs` / `sandbox` / `scope` / `registry` / `instructions` / `lsp` / `workspace-files` / `command`, plus the client carrier row `multi-root-client`); `bash-sandbox` stays upstream (bash and the PTY backend take their roots from `ctx.sandbox`). After starting `dsh --profile web`, the Folders action appears at the sidebar foot.
|
|
150
150
|
|
|
151
151
|
## Usage
|
|
152
152
|
|
|
@@ -211,10 +211,10 @@ Issues and PRs are welcome:
|
|
|
211
211
|
|
|
212
212
|
- An additional root's instruction files arrive as they become relevant: the one at the root's top level is injected before the session's first step, and a subdirectory's is injected once the session has **successfully** worked in that directory. A nested file is re-examined only when its directory is examined (the root's own every step; a subdirectory's because it was delivered from, or because of a fresh touch), delivery state is in-process (so a resumed session may be told again), and only the `read` / `write` / `edit` tool names count. The primary root's chain and the user-global file remain upstream's job, and this plugin does not inject them a second time ([ADR-0010](./docs/decisions/ADR-0010-additional-root-instruction-scope.md)).
|
|
213
213
|
- Single writer per store: only one DSH process at a time may hold the root registry for a given `$DSH_HOME`; another process reports the registry as unavailable (`registry-contended`) and takes over on refresh once the holder exits or crashes. That is deliberate fail-closed behavior, not a race waiting to be fixed ([ADR-0007](./docs/decisions/ADR-0007-registry-authority-lease.md)).
|
|
214
|
-
- The supported matrix is an exact-version allowlist: on a host whose release is not on the list, or whose core packages disagree about the release, the `fs` / `sandbox` / `registry` / `instructions` rows **do not start** and the composition degrades to "the plugin is not installed" ([ADR-0009](./docs/decisions/ADR-0009-dsh-compat-contract.md)).
|
|
215
|
-
-
|
|
214
|
+
- The supported matrix is an exact-version allowlist: on a host whose release is not on the list, or whose core packages disagree about the release, the `fs` / `sandbox` / `registry` / `instructions` / `lsp` / `workspace-files` rows **do not start** and the composition degrades to "the plugin is not installed" ([ADR-0009](./docs/decisions/ADR-0009-dsh-compat-contract.md)).
|
|
215
|
+
- The Windows multi-root runner inherits upstream partial enforcement, caller-owned directory requirements, and private-temp isolation. Running processes retain their initial roots; later processes use the updated set ([ADR-0011](./docs/decisions/ADR-0011-multi-root-workspace-consumers.md)).
|
|
216
216
|
- An additional root has the same rights as the primary root (no per-root read-only), and cannot become the default working directory of bash/PTY (session cwd semantics are unchanged).
|
|
217
|
-
- The
|
|
217
|
+
- Browse additional roots in the Workspace Folders dialog with manual refresh, expandable directories, and previews of up to 200 text lines. The native primary-root Files tab remains and offers a dialog action where supported. LSP uses the containing additional root as its own workspace; the host must configure the relevant language server ([ADR-0011](./docs/decisions/ADR-0011-multi-root-workspace-consumers.md)).
|
|
218
218
|
- The command's own output text is English (a host-side handler has no active locale to consult); the panel is bilingual.
|
|
219
219
|
- The Workspace Folders panel is a sidebar footer action plus a dialog rather than a full panel: `sidebar.footer.action` is offered by every supported release, whereas `sidebar.panellist` / `main` are not.
|
|
220
220
|
|
|
@@ -236,3 +236,5 @@ Repository-wide rules for Coding Agents are defined in [`AGENTS.md`](./AGENTS.md
|
|
|
236
236
|
## License
|
|
237
237
|
|
|
238
238
|
[MIT](./LICENSE)
|
|
239
|
+
|
|
240
|
+
Dynamic working directories affect relative path resolution and new processes. They do not grant access or change the session origin that owns the root registry. See [ADR-0012](./docs/decisions/ADR-0012-session-origin-and-effective-cwd.md).
|
package/README.md
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
|
|
7
7
|
DSH(DeepSeek Harness)的外部插件 bundle:把 Workspace 的可写范围从"一个 canonical 目录"扩展为"**一个主根 + N 个附加根**",且**不修改上游仓库任何包**。
|
|
8
8
|
|
|
9
|
-
它解决的问题是:一个开发项目往往由多个独立 Git Repository 组成,而 DSH
|
|
9
|
+
它解决的问题是:一个开发项目往往由多个独立 Git Repository 组成,而 DSH 原生只把会话原始项目当作唯一的可写根,Agent 跨仓库干活就得反复换会话。
|
|
10
10
|
|
|
11
11
|
这个插件的三个核心价值:
|
|
12
12
|
|
|
@@ -24,7 +24,7 @@ DSH(DeepSeek Harness)的外部插件 bundle:把 Workspace 的可写范围
|
|
|
24
24
|
|
|
25
25
|
**已完成并发布:`v0.1.4`**——在 `v0.1.3` 契约不变的前提下,受支持的上游运行时扩展到 `0.1.7-rc.2`(形状与 `0.1.7-rc.1` 相同,适配层无新分支;cordis 仍是 `~4.0.4`)。详见 [CHANGELOG](./CHANGELOG.md)。
|
|
26
26
|
|
|
27
|
-
|
|
27
|
+
**v0.1.5 已发布**。当前开发分支包含尚未发布的 DSH `0.2.1-alpha.1` / `0.2.1-alpha.2` 支持、动态 cwd / Session origin 分离,以及 LSP、Windows ACL、附加根文件浏览与 Worktree 能力;这些变更拟纳入 `v0.1.6`,发布状态见[路线账本](./docs/plans/active/2026-09-12-multi-root-workspace.md)。
|
|
28
28
|
|
|
29
29
|
进度、编号与发布状态的唯一真源是[路线图 §进度总账](./docs/plans/active/2026-09-12-multi-root-workspace.md#进度总账)(M1–M4 是 MVP 里程碑编号,H1–H4 是 `v0.1.1` 批次编号,其中 H1 即 M4);逐项证据见各[已完成计划](./docs/plans/README.md),每个版本的用户可见变更见 [CHANGELOG](./CHANGELOG.md)。
|
|
30
30
|
|
|
@@ -45,17 +45,17 @@ dsh --profile web
|
|
|
45
45
|
/workspace-folders add ~/code/another-repo
|
|
46
46
|
```
|
|
47
47
|
|
|
48
|
-
之后 Agent 即可在该目录读写、跑 bash
|
|
48
|
+
之后 Agent 即可在该目录读写、跑 bash——与本会话的主根同权。DSH 的动态 working directory 只影响新操作的相对路径和执行目录,切换 cwd 不会新增授权,也不会改变注册表归属。
|
|
49
49
|
|
|
50
50
|
## 环境要求
|
|
51
51
|
|
|
52
|
-
- **使用本源码构建的插件**:需要一个受支持的 DSH 运行时 —— 当前是 **`0.1.5-rc.2`、`0.1.6-alpha.1`、`0.1.6-alpha.2`、`0.1.7-alpha.1`、`0.1.7-alpha.2`、`0.1.7-rc.1`、`0.1.7-rc.2`、`0.2.0-rc.1` 与 `0.2.
|
|
52
|
+
- **使用本源码构建的插件**:需要一个受支持的 DSH 运行时 —— 当前是 **`0.1.5-rc.2`、`0.1.6-alpha.1`、`0.1.6-alpha.2`、`0.1.7-alpha.1`、`0.1.7-alpha.2`、`0.1.7-rc.1`、`0.1.7-rc.2`、`0.2.0-rc.1`、`0.2.0-rc.2`、`0.2.1-alpha.1` 与 `0.2.1-alpha.2`**,别的版本装不上也不会跑(见下)。`dsh plugin` 会把包装进对应 profile,无需本地 Node 工具链
|
|
53
53
|
- **从源码构建 / 参与**:**Node.js** `^22.19.0 || >=24`(仓库 `engines` 钉住)、**Git**、**pnpm 11**(`packageManager` 钉 `pnpm@11.25.0`,建议经 corepack 启用)
|
|
54
|
-
- **DSH 运行时**:开发依赖精确 pin 在 `0.2.
|
|
55
|
-
- **平台支持**:macOS
|
|
54
|
+
- **DSH 运行时**:开发依赖精确 pin 在 `0.2.1-alpha.2`(受支持版本里的基线);升级流程见[开发工作流](./docs/development/plugin-development-workflow.md)
|
|
55
|
+
- **平台支持**:macOS Seatbelt / Linux bwrap、Landlock;当前开发分支还实现 Windows root-set ACL runner,平台验证状态见[路线账本](./docs/plans/active/2026-09-12-multi-root-workspace.md#b1b3第二期-p12026-10-02)。
|
|
56
56
|
- 运行冒烟测试**不需要模型凭据**:e2e 的模型轮次由内联的脚本化模型端点提供
|
|
57
57
|
|
|
58
|
-
**受支持的 DSH 版本是一份精确清单,不是一个范围。** 因为本插件替换的是 `ctx.fs` 与 `ctx.sandbox`——安全边界本身——而它识别内核沙箱方言靠的是对具体上游版本实测出来的 argv 形状。所以 `peerDependencies` 只列真正跑过全套验证的版本,启动时也会再查一遍:宿主的版本不在清单上,或者若干个 `@deepseek-ai/dsh-*` 混装了不同版本,那么 fs / sandbox / registry / instructions
|
|
58
|
+
**受支持的 DSH 版本是一份精确清单,不是一个范围。** 因为本插件替换的是 `ctx.fs` 与 `ctx.sandbox`——安全边界本身——而它识别内核沙箱方言靠的是对具体上游版本实测出来的 argv 形状。所以 `peerDependencies` 只列真正跑过全套验证的版本,启动时也会再查一遍:宿主的版本不在清单上,或者若干个 `@deepseek-ai/dsh-*` 混装了不同版本,那么 fs / sandbox / registry / instructions / lsp / workspace-files 六行**不启动**,组合退化成"没装这个插件",并打印一条说明。诊断办法见[故障排查:DSH 版本不在支持矩阵上](./docs/troubleshooting/unsupported-dsh-release.md),理由见 [ADR-0009](./docs/decisions/ADR-0009-dsh-compat-contract.md)。
|
|
59
59
|
|
|
60
60
|
## 安装
|
|
61
61
|
|
|
@@ -148,7 +148,7 @@ dsh plugin --profile web add "$PWD"
|
|
|
148
148
|
dsh --profile web --dump-config
|
|
149
149
|
```
|
|
150
150
|
|
|
151
|
-
预期:组合里**仅** `fs-sandbox` 与 `sandbox` 两行被替换为插件的 `multi-root-fs` / `multi-root-sandbox`,并插入
|
|
151
|
+
预期:组合里**仅** `fs-sandbox` 与 `sandbox` 两行被替换为插件的 `multi-root-fs` / `multi-root-sandbox`,并插入 10 行(`multi-root-compat` / `fs` / `sandbox` / `scope` / `registry` / `instructions` / `lsp` / `workspace-files` / `command` 与 client 载体行 `multi-root-client`);`bash-sandbox` 保持上游(bash 与 PTY 经 `ctx.sandbox` 取根)。启动 `dsh --profile web` 后,侧栏底部出现 Folders 动作。
|
|
152
152
|
|
|
153
153
|
## 使用方法
|
|
154
154
|
|
|
@@ -213,10 +213,10 @@ docs/ 需求、架构、决策记录(ADR)、计划、开发工
|
|
|
213
213
|
|
|
214
214
|
- 附加根的指令文件按需到达模型:根目录顶层的那一份在会话第一步之前注入,子目录里的那一份在本会话**成功**触碰过该目录之后注入;nested 文件只会在其目录被考察到时重新检查(根层每一步,子目录依赖已投递或有新触碰),投递状态是进程内的(resume 后可能再告知一次),也只识别 `read` / `write` / `edit` 三个工具名。主根与 user-global 的指令链仍由上游负责,本插件不重复注入([ADR-0010](./docs/decisions/ADR-0010-additional-root-instruction-scope.md))。
|
|
215
215
|
- 跨进程单写者:同一 `$DSH_HOME` 上同时只允许一个 DSH 进程持有根登记表;另一个进程显示登记表不可用(`registry-contended`),持锁者退出或崩溃后刷新即接管——这是刻意的 fail-closed,不是待修的竞态([ADR-0007](./docs/decisions/ADR-0007-registry-authority-lease.md))。
|
|
216
|
-
- 支持矩阵是精确版本 allowlist:宿主版本不在清单上、或核心包混装了不同版本时,`fs` / `sandbox` / `registry` / `instructions`
|
|
217
|
-
- Windows
|
|
216
|
+
- 支持矩阵是精确版本 allowlist:宿主版本不在清单上、或核心包混装了不同版本时,`fs` / `sandbox` / `registry` / `instructions` / `lsp` / `workspace-files` 六行**不启动**,组合退化为"没装这个插件"([ADR-0009](./docs/decisions/ADR-0009-dsh-compat-contract.md))。
|
|
217
|
+
- Windows 多根 runner 继承上游 partial enforcement、caller-owned 目录及 private temp 分离条件;已启动进程保留启动时根集合,后续进程使用更新后的集合([ADR-0011](./docs/decisions/ADR-0011-multi-root-workspace-consumers.md))。
|
|
218
218
|
- 附加根与主根同权(无 per-root read-only);附加根不能作为 bash/PTY 的默认工作目录(session cwd 语义不变)。
|
|
219
|
-
-
|
|
219
|
+
- 附加根文件树位于“工作区目录”对话框,采用手动刷新;可展开目录和预览前 200 行文本。主根原生 Files tab 保留,有 actions slot 时提供打开该对话框的入口。LSP 按附加文件所在根初始化独立 workspace;需要宿主配置对应语言服务器([ADR-0011](./docs/decisions/ADR-0011-multi-root-workspace-consumers.md))。
|
|
220
220
|
- 命令的输出文案为英文(host 侧没有活动语言信息),面板文案中英双语跟随界面语言。
|
|
221
221
|
- Workspace Folders 面板是「侧栏底部动作 + 对话框」,不是独立全屏面板:`sidebar.footer.action` 是所有受支持版本都提供的插槽,而 `sidebar.panellist`/`main` 不是。
|
|
222
222
|
|
package/cordis.patch.yml
CHANGED
|
@@ -59,6 +59,10 @@
|
|
|
59
59
|
name: '@dsh-electron/dsh-plugin-multi-root-workspace/instructions'
|
|
60
60
|
config:
|
|
61
61
|
maxBytes: 65536
|
|
62
|
+
- id: multi-root-lsp
|
|
63
|
+
name: '@dsh-electron/dsh-plugin-multi-root-workspace/lsp'
|
|
64
|
+
- id: multi-root-workspace-files
|
|
65
|
+
name: '@dsh-electron/dsh-plugin-multi-root-workspace/workspace-files'
|
|
62
66
|
- id: multi-root-command
|
|
63
67
|
name: '@dsh-electron/dsh-plugin-multi-root-workspace/command'
|
|
64
68
|
- id: multi-root-client
|