dsh-oh-my-claude 1.5.13 → 1.6.0

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.
Files changed (89) hide show
  1. package/CHANGELOG.md +48 -3
  2. package/README.md +21 -5
  3. package/README.zh.md +21 -5
  4. package/lib/client.js +67 -76
  5. package/lib/server/adapter/asides.d.ts +2 -2
  6. package/lib/server/adapter/asides.js +3 -3
  7. package/lib/server/adapter/asides.js.map +1 -1
  8. package/lib/server/adapter/class.d.ts +73 -8
  9. package/lib/server/adapter/class.js +394 -44
  10. package/lib/server/adapter/class.js.map +1 -1
  11. package/lib/server/adapter/cli-compaction.d.ts +50 -0
  12. package/lib/server/adapter/cli-compaction.js +36 -0
  13. package/lib/server/adapter/cli-compaction.js.map +1 -0
  14. package/lib/server/adapter/cli.js +4 -0
  15. package/lib/server/adapter/cli.js.map +1 -1
  16. package/lib/server/adapter/config.d.ts +6 -2
  17. package/lib/server/adapter/config.js +7 -3
  18. package/lib/server/adapter/config.js.map +1 -1
  19. package/lib/server/adapter/spawn-mode.d.ts +51 -0
  20. package/lib/server/adapter/spawn-mode.js +51 -0
  21. package/lib/server/adapter/spawn-mode.js.map +1 -0
  22. package/lib/server/adapter/ssh-boxes.js +2 -2
  23. package/lib/server/adapter/ssh-boxes.js.map +1 -1
  24. package/lib/server/adapter.js +5 -1
  25. package/lib/server/adapter.js.map +1 -1
  26. package/lib/server/dsh.d.ts +36 -15
  27. package/lib/server/hold.d.ts +2 -0
  28. package/lib/server/hold.js +1 -0
  29. package/lib/server/hold.js.map +1 -1
  30. package/lib/server/keeper.js +37 -0
  31. package/lib/server/keeper.js.map +1 -1
  32. package/lib/server/mcp.d.ts +13 -0
  33. package/lib/server/mcp.js +50 -10
  34. package/lib/server/mcp.js.map +1 -1
  35. package/lib/server/process.d.ts +43 -8
  36. package/lib/server/process.js +129 -12
  37. package/lib/server/process.js.map +1 -1
  38. package/lib/server/routes/controls.js +8 -3
  39. package/lib/server/routes/controls.js.map +1 -1
  40. package/lib/server/rows-probe.js +13 -8
  41. package/lib/server/rows-probe.js.map +1 -1
  42. package/lib/server/sessions.d.ts +25 -12
  43. package/lib/server/sessions.js +27 -19
  44. package/lib/server/sessions.js.map +1 -1
  45. package/lib/server/state.d.ts +7 -4
  46. package/lib/server/state.js +7 -7
  47. package/lib/server/state.js.map +1 -1
  48. package/lib/server/update.d.ts +16 -0
  49. package/lib/server/update.js +9 -0
  50. package/lib/server/update.js.map +1 -1
  51. package/package.json +3 -4
  52. package/src/adapter/asides.ts +3 -3
  53. package/src/adapter/class.ts +411 -43
  54. package/src/adapter/cli-compaction.ts +70 -0
  55. package/src/adapter/cli.ts +8 -0
  56. package/src/adapter/config.ts +13 -5
  57. package/src/adapter/spawn-mode.ts +81 -0
  58. package/src/adapter/ssh-boxes.ts +2 -2
  59. package/src/adapter.ts +5 -1
  60. package/src/client/context-meter.ts +26 -3
  61. package/src/client/cost.tsx +22 -29
  62. package/src/client/dock.tsx +1 -1
  63. package/src/client/events.ts +1 -1
  64. package/src/client/i18n/main.ts +22 -20
  65. package/src/client/i18n/misc.ts +6 -0
  66. package/src/client/i18n/panel.ts +5 -0
  67. package/src/client/index.tsx +5 -7
  68. package/src/client/keeper-switch.tsx +75 -0
  69. package/src/client/panel/asides.tsx +1 -1
  70. package/src/client/panel/diagnostics.tsx +7 -2
  71. package/src/client/panel/restore.tsx +49 -21
  72. package/src/client/selection-actions.tsx +478 -0
  73. package/src/client/selection.ts +55 -89
  74. package/src/client/settings-card.tsx +2 -1
  75. package/src/client/shared.ts +27 -18
  76. package/src/client/turn-status.tsx +1 -1
  77. package/src/client/ultrathink.ts +54 -187
  78. package/src/client/update-pill.tsx +33 -10
  79. package/src/dsh.ts +42 -21
  80. package/src/hold.ts +3 -0
  81. package/src/keeper.ts +36 -1
  82. package/src/mcp.ts +53 -12
  83. package/src/process.ts +142 -14
  84. package/src/routes/controls.ts +8 -2
  85. package/src/rows-probe.ts +13 -8
  86. package/src/sessions.ts +39 -19
  87. package/src/state.ts +8 -7
  88. package/src/update.ts +22 -0
  89. package/src/client/selection-bar.tsx +0 -373
package/CHANGELOG.md CHANGED
@@ -6,6 +6,51 @@ Versions from 1.0.0 up are on npm. Everything below 1.0.0 was released from the
6
6
 
7
7
  ## [Unreleased]
8
8
 
9
+ ## [1.6.0] - 2026-11-08
10
+
11
+ dsh: runs on 0.2.2-alpha.2 through 0.2.2-rc.1; built and tested on 0.2.2-rc.1. On dsh 0.2.0 or 0.2.1, stay on 1.5.14 (npm tag `dsh-0.2.1`).
12
+
13
+ ### Added
14
+
15
+ - A plugin release your dsh is too old for is no longer silent: the update pill shows "1.6.0 needs dsh 0.2.2-alpha.2" (the release and the dsh it needs, both read from npm), with no command to copy until dsh is updated.
16
+ - A switch under Settings → Oh My Claude, Keep Claude running across dsh restarts. On, as before, Claude Code runs under a keeper and survives a restart. Off, it runs inside dsh through its subprocess seam and ends with dsh, along with everything it started; on an SSH box or a remote workspace the far `claude` ends with the ssh connection. Thanks to @fancn (#241).
17
+
18
+ ### Changed
19
+
20
+ - `spawn` has no default in the config any more. Unset, or `keeper`, the new switch decides; `node` or `dsh` still wins and shows the switch locked.
21
+ - Under `spawn: dsh` the plugin passes the credential-shaped variables dsh runs with (`ANTHROPIC_API_KEY`, `ANTHROPIC_AUTH_TOKEN`, `GH_TOKEN` and the rest) through dsh's environment scrub, and puts the installer folders on `PATH`, so Claude starts and logs in as it does under a keeper. Thanks to @fancn (#241).
22
+ - The selection bar is gone; Ask moved into dsh's own selection popover (dsh 0.2.2), beside its Quote text. dsh shows one plugin's popover per selection, so the plugin draws dsh's Quote text there itself, doing what dsh's does: the passage goes into the composer as dsh's quote chip. Ask turns the popover into a question box (Enter asks, Shift+Enter starts a new line, Escape closes) that stays beside the passage as the chat scrolls, and sends the passage as an aside, as before. Both buttons take the Claude accent in a Claude session. On a phone or tablet, where the device's own selection toolbar covers dsh's popover, the same two buttons sit in a row above the composer instead. The plugin's own Quote, which wrote the passage as Markdown into the draft, is gone. The Settings switch is now "Ask about a selection" and hides only Ask. Thanks to @fancn (#242).
23
+ - The plugin now needs dsh 0.2.2-alpha.2 or newer, the first dsh with the selection popover and its quote chip: `engines.dsh` and the `@deepseek-ai/dsh-llm` peer range both start there. On dsh 0.2.0 or 0.2.1, stay on 1.5.14.
24
+ - A quote in a message you sent now shows as dsh's own quote chip (dsh 0.2.2); the plugin no longer lays its own quote block over the message. The composer still dims quoted lines while you type, now by dsh's own rule: `>5 items` and a `>` line inside a code fence count, a lone `>` does not, and a chip in the composer is skipped.
25
+ - dsh's compaction of a Claude session runs Claude Code's own `/compact` and takes its summary. dsh measures the prompt the CLI reports, which its one-shot summary of dsh's own copy never lowered, so past its threshold it compacted before every step (33 one-shot summaries in one team member's turns). A compaction asked for mid-turn waits until the session is idle, a subagent's or team member's until its next turn starts, and a compaction the CLI makes on its own reaches dsh's copy without another model call. Switch: `cliCompaction`, on by default. Thanks to @fancn (#243).
26
+
27
+ ### Fixed
28
+
29
+ - A keeper no dsh has attached to for `processIdleMs` (30 minutes by default, never under 5 minutes), while Claude writes nothing, now ends its Claude. Keepers used to run until someone killed them. Thanks to @fancn (#241).
30
+ - An idle Claude process is ended after `processIdleMs` on its own, checked every 30 seconds, unless a background task is still running. It used to wait until another session started one. Thanks to @fancn (#241).
31
+ - A dsh restart no longer wakes an idle session with "dsh restarted and reattached" over a frame that was not Claude's output, such as a reply to a control request that arrived late. Thanks to @fancn (#241).
32
+ - DSH Web and DSH Desktop on one machine reattach only to their own Claude processes and leave each other's restart nudges alone; the one that started later used to take over the other's sessions. Thanks to @fancn (#241).
33
+ - `open_session` with a provider and model reports an error when the new session has no model route to set, instead of opening it on dsh's default model without a word, and archives the empty session it created. Thanks to @tusharcora (#240).
34
+ - On Windows, restoring a transcript from the ✻ panel opens it. The plugin could not read dsh's session-format catalog from a Windows path, so it wrote the session in a format dsh refuses. Native tool rows and the session-log repair, which read the same catalog, now work on Windows too. Thanks to @kiluahh (#246).
35
+ - A restore that fails now shows why under its row; the click used to look like it did nothing.
36
+
37
+ ## [1.5.14] - 2026-11-05
38
+
39
+ dsh: runs on 0.2.0-rc.1 through 0.2.2-rc.1; built and tested on 0.2.2-rc.1.
40
+
41
+ ### Fixed
42
+
43
+ - The cost pill keeps working on the dsh after 0.2.2-rc.1. That build drops the positioning hook its dialog was placed with, and the pill would crash on render and disappear. The dialog is now placed with CSS anchor positioning, the way that build places its own stat dialogs, and opens in the same place on 0.2.2-rc.1. Thanks to @fancn (#236).
44
+ - The context ring's hover tooltip shows the Claude usage line and the CLI's context count again. dsh 0.2.2-alpha.3 moved that tooltip to the end of the page, and the plugin no longer recognised it as the ring's. Thanks to @fancn (#236).
45
+ - `open_session` from Claude opens the new session on the provider and model it names again. On dsh 0.2 it failed with `selectForNextRequest is not a function` whenever both were given, and left an empty session behind. The pick applies to that session only; the default model for new sessions is unchanged.
46
+ - dsh's Back-to-bottom button can be clicked again while Claude's working line shows above the composer. On dsh 0.2.2 the composer area is drawn over the button, so the line covered it and took the click.
47
+ - Under a code-mode agent preset (dsh's `ptc`), Claude gets only `run_code` from dsh, as the preset intends, instead of every dsh tool one by one, and is told to reach subagents from its programs. Thanks to @tusharcora (#234).
48
+ - A Claude session that sat idle when dsh restarted is no longer woken with "dsh restarted and reattached … Continue where you are." Reattaching re-sends the CLI its `initialize`, and the CLI answers that with a snapshot of its background tasks; the plugin read the snapshot as output written while dsh was away and opened a turn for it, one model call per idle session per restart. A session that could not be woken (a dsh subagent's) kept the snapshot unread instead: the plugin retried the wake every 2 s for a minute, and the keeper replayed the snapshot after the next restart, one more each time. The snapshot is now used on arrival, so neither happens. A session that did work while dsh was away, a reply or a background task that finished, is still woken to show it. Thanks to @fancn (#232).
49
+
50
+ ### Removed
51
+
52
+ - The plugin no longer asks dsh for `@deepseek-ai/dsh-client-runtime`, a package dsh has deleted. dsh skipped the missing name, so nothing changes on screen. Thanks to @zhu1090093659 for spotting it in the community index review.
53
+
9
54
  ## [1.5.13] - 2026-11-04
10
55
 
11
56
  dsh: runs on 0.2.0-rc.1 through 0.2.2-rc.1; built and tested on 0.2.2-rc.1.
@@ -227,13 +272,13 @@ dsh: runs on 0.2.0-rc.1 through 0.2.0-rc.2; built and tested on 0.2.0-rc.2.
227
272
 
228
273
  ### Fixed
229
274
 
230
- - On Windows the Memory, Instructions, Skills, MCP, Rewind and Restore tabs and the workspace search answer for a session opened in a drive path (`C:\work\repo`). Every one of them refused the directory with a 400, and Plugins, Diagnostics and the feature switches silently lost their project and local scopes. The managed settings and managed CLAUDE.md are read from the CLI's own directory for the OS (`C:\Program Files\ClaudeCode`, `/Library/Application Support/ClaudeCode`), and a `configDir` given as a drive path is no longer joined onto the working directory.
231
- - The Memory tab lists the memories Claude actually wrote. Claude Code keys auto-memory by repository, so a session opened in a linked worktree or in a subdirectory shares the main checkout's memory; the tab looked under the session's own directory and showed an empty list. It also follows `autoMemoryDirectory` from the managed and user settings.
275
+ - On Windows the Memory, Instructions, Skills, MCP, Rewind and Restore tabs and the workspace search answer for a session opened in a drive path (`C:\work\repo`). Every one of them refused the directory with a 400, and Plugins, Diagnostics and the feature switches silently lost their project and local scopes. The managed settings and managed CLAUDE.md are read from the CLI's own directory for the OS (`C:\Program Files\ClaudeCode`, `/Library/Application Support/ClaudeCode`), and a `configDir` given as a drive path is no longer joined onto the working directory. Thanks to @Clemens66666 (#145).
276
+ - The Memory tab lists the memories Claude actually wrote. Claude Code keys auto-memory by repository, so a session opened in a linked worktree or in a subdirectory shares the main checkout's memory; the tab looked under the session's own directory and showed an empty list. It also follows `autoMemoryDirectory` from the managed and user settings. Thanks to @Clemens66666 (#146).
232
277
  - A session opened in a subdirectory of a repository, or in a linked worktree, reads the files the CLI reads. The Settings editor's local scope, the feature switches and the plugin roster use the `settings.local.json` at the repository's root, where the CLI keeps it, and still count the session directory's own file below it. The MCP tab lists local-scope servers, which the CLI files under the repository's root, and project servers from a `.mcp.json` in any directory above the session's. The Skills tab lists project skills from each directory up to the repository's root. Before, all four looked only in the session's own directory.
233
278
  - A workspace whose path is longer than 200 characters resumes its Claude session and lists its transcripts and memory. Claude Code shortens such a directory name and adds a hash, and the plugin looked for the unshortened name.
234
279
  - On a Windows host the workspace search works without `grep`, and session rows, workspace names and saved-memory lines show the last part of a `C:\...` path instead of the whole of it.
235
280
  - On a Windows box where Claude Code runs commands through its PowerShell tool, a command shows as a shell card with its text, the approval dialog shows the command instead of its arguments as JSON, and the suggested permission rule covers that command (`PowerShell(git status *)`) instead of the whole tool. Only `Bash` was handled before.
236
- - The note that tells Claude which dsh tools to use names only the tools the session has. It used to name `mcp__dsh__bash` on Windows, where dsh offers `mcp__dsh__pwsh`, and `mcp__dsh__list_subagent_models` and preset subagent tools in sessions that have neither, so Claude went looking for them and fell back to a native background shell dsh cannot see.
281
+ - The note that tells Claude which dsh tools to use names only the tools the session has. It used to name `mcp__dsh__bash` on Windows, where dsh offers `mcp__dsh__pwsh`, and `mcp__dsh__list_subagent_models` and preset subagent tools in sessions that have neither, so Claude went looking for them and fell back to a native background shell dsh cannot see. Thanks to @Clemens66666 (#147).
237
282
 
238
283
  ## [1.5.1] - 2026-09-29
239
284
 
package/README.md CHANGED
@@ -57,7 +57,7 @@ Once an SSH box is saved, dsh's own Add workspace dialog gains a box dropdown: a
57
57
 
58
58
  ## Install
59
59
 
60
- You need the Claude Code CLI on `PATH` and logged in (`claude --version` works, `claude` opens without asking you to sign in), and dsh 0.2 (0.2.0-rc.1 or newer). On dsh 0.1.x, install the npm tag for your line from the Compatibility table below. Nothing else: no API key, no Node build step.
60
+ You need the Claude Code CLI on `PATH` and logged in (`claude --version` works, `claude` opens without asking you to sign in), and dsh 0.2 (0.2.2-alpha.2 or newer). On dsh 0.2.0 or 0.2.1, install 1.5.14 (`dsh-oh-my-claude@dsh-0.2.1`); on dsh 0.1.x, install the npm tag for your line from the Compatibility table below. Nothing else: no API key, no Node build step.
61
61
 
62
62
  **From dsh's Plugins page**, in the web app or DSH Desktop:
63
63
 
@@ -101,11 +101,13 @@ Working on the plugin itself? Start at [docs/developing.md](https://github.com/l
101
101
 
102
102
  ## Compatibility
103
103
 
104
- dsh ships prereleases only and moves client APIs between them, so every release of the plugin records the dsh line it was written for and the dsh it was driven on. "Runs on" is the range the code carries branches for; "tested on" is the dsh installed on the box when the release was cut. The update pill reads the floor off the registry and never offers a release to a box whose dsh is below it.
104
+ dsh ships prereleases only and moves client APIs between them, so every release of the plugin records the dsh line it was written for and the dsh it was driven on. "Runs on" is the range the code carries branches for; "tested on" is the dsh installed on the box when the release was cut. The update pill reads the floor off the registry: a box whose dsh is below it is never offered the update command, and the pill names the dsh that release needs instead.
105
105
 
106
106
  | Plugin | Runs on dsh | Tested on dsh | npm tag |
107
107
  | --- | --- | --- | --- |
108
- | 1.5.13 | 0.2.0-rc.1 through 0.2.2-rc.1 | 0.2.2-rc.1 | `latest`, `dsh-0.2` |
108
+ | 1.6.0 | 0.2.2-alpha.2 through 0.2.2-rc.1 | 0.2.2-rc.1 | `latest` |
109
+ | 1.5.14 | 0.2.0-rc.1 through 0.2.2-rc.1 | 0.2.2-rc.1 | `dsh-0.2.1`, `dsh-0.2` |
110
+ | 1.5.13 | 0.2.0-rc.1 through 0.2.2-rc.1 | 0.2.2-rc.1 | none, superseded by 1.5.14 |
109
111
  | 1.5.12 | 0.2.0-rc.1 through 0.2.2-alpha.2 | 0.2.2-alpha.2 | none, superseded by 1.5.13 |
110
112
  | 1.5.11 | 0.2.0-rc.1 through 0.2.2-alpha.2 | 0.2.2-alpha.2 | none, superseded by 1.5.12 |
111
113
  | 1.5.10 | 0.2.0-rc.1 through 0.2.2-alpha.2 | 0.2.2-alpha.2 | none, superseded by 1.5.11 |
@@ -148,7 +150,7 @@ dsh ships prereleases only and moves client APIs between them, so every release
148
150
  21. dsh's own goal and every earlier goal of the session, beside Claude Code's goal and its scheduled tasks. [Tasks](https://github.com/lcestou/dsh-oh-my-claude/blob/main/docs/panel.md#tasks)
149
151
  22. Edit or remove a message you steered in while Claude works, or all of them as one, until Claude reads it. A file or image on the message stays on it; only the text changes. Nothing goes out while you edit. Send now stops Claude and sends one as the next turn. [Steering](https://github.com/lcestou/dsh-oh-my-claude/blob/main/docs/how-it-works.md#dsh-tools-over-mcp)
150
152
  23. Claude's working line (spinner, verb, figures) repeats above the composer once you scroll up past it, so reading back through a long turn never hides what Claude is doing. A switch in Settings turns it off. [Turn status](https://github.com/lcestou/dsh-oh-my-claude/blob/main/docs/how-it-works.md#turn-status)
151
- 24. Select text in a reply to quote it into your message, or to ask Claude about it as a side question that leaves the conversation alone; leave the question blank and Claude explains the passage. A quote in your own message reads like one in Claude's replies, indented with the accent bar. [Asides](https://github.com/lcestou/dsh-oh-my-claude/blob/main/docs/panel.md#asides)
153
+ 24. Select text in a reply and dsh's popover (dsh 0.2.2) shows Ask beside its Quote text, or on a phone a row above the composer does: ask Claude about the passage as a side question that leaves the conversation alone; ask with the question blank and Claude explains the passage. [Asides](https://github.com/lcestou/dsh-oh-my-claude/blob/main/docs/panel.md#asides)
152
154
  25. A finished turn keeps a closing line where the working verb was, the way the terminal ends one: `✻ Crunched for 27s · done 3:21 AM`. A turn you stopped reads `Interrupted · What should Claude do instead?`. [Turn status](https://github.com/lcestou/dsh-oh-my-claude/blob/main/docs/how-it-works.md#turn-status)
153
155
  26. On dsh 0.1.7, Claude's tool calls show as dsh's own tool cards, the way every other provider's do, with the text streaming between them. Inline text is a switch away in Settings. [Tool rows](https://github.com/lcestou/dsh-oh-my-claude/blob/main/docs/configuration.md)
154
156
  27. A new session in a workspace opens on the Claude box, model and effort that workspace last ran, and a workspace with nothing remembered opens on a default model and effort you pick. [Remember model per workspace](https://github.com/lcestou/dsh-oh-my-claude/blob/main/docs/panel.md#remember-model-per-workspace)
@@ -172,12 +174,26 @@ Settings come in two kinds. The switches under Settings → Oh My Claude and in
172
174
 
173
175
  ```yaml
174
176
  permissionMode: dsh # follow the session's shield (default), or pin one of the CLI's six modes
175
- spawn: keeper # Claude outlives a dsh restart (default); node or dsh for a plain child
177
+ # spawn: node # unset: the Settings switch below decides; node or dsh here wins
176
178
  sshHost: "" # "[user@]host" drives a claude on another machine over ssh
177
179
  ```
178
180
 
179
181
  Every key, with its default, is in [docs/configuration.md](https://github.com/lcestou/dsh-oh-my-claude/blob/main/docs/configuration.md).
180
182
 
183
+ ### Keep Claude running across dsh restarts
184
+
185
+ This switch under Settings → Oh My Claude picks how Claude Code is started, and it is on unless you turn it off. `spawn: node` or `spawn: dsh` in the config overrides it and locks the switch; `spawn: keeper` leaves it free. A flip reaches each session on its next turn.
186
+
187
+ | | On (`keeper`) | Off (`dsh`) | `node` (config only) |
188
+ |---|---|---|---|
189
+ | A turn running when dsh restarts | Keeps running; the new dsh reattaches and shows what it did | Ends; about ten seconds after the restart the session gets a "dsh restarted while this turn was in progress" prompt and carries on | Same as off |
190
+ | Left running after dsh exits | Claude, until it has gone `processIdleMs` (30 min, never under 5 min) with no dsh attached and no output | Nothing after a normal shutdown: dsh ends Claude and everything it started | Claude ends when dsh does; what it started is not tracked |
191
+ | dsh's environment | Passed whole | Passed whole except `DSH_*` names: dsh's seam drops names with KEY, TOKEN, SECRET or PASSWORD, and the plugin passes them back | Passed whole |
192
+ | SSH boxes and remote workspaces | The far `claude` is held on the box and survives too; the idle limit above does not reach it, so it runs until a dsh reattaches or the box restarts | The far `claude` ends with the ssh connection | Same as off |
193
+ | Platforms | Linux and macOS; Windows runs `node` | All; `node` when dsh mounts no subprocess seam | All |
194
+
195
+ DSH Web and DSH Desktop run separate dsh profiles, so each reattaches only to the Claude processes it started. Two dsh started on the same profile directory still share them.
196
+
181
197
  ## Remote boxes and accounts
182
198
 
183
199
  Mount the plugin twice with different `configDir` values for two logins. List other boxes running dsh and this plugin under Settings → Oh My Claude → Boxes and jump between them. Or give a box a name and `user@host` and drive the `claude` there over SSH, with nothing on the far side but the CLI; Tailscale and WireGuard peers appear as hosts to pick from. All of it is on [docs/remote.md](https://github.com/lcestou/dsh-oh-my-claude/blob/main/docs/remote.md).
package/README.zh.md CHANGED
@@ -59,7 +59,7 @@
59
59
 
60
60
  ## 安装
61
61
 
62
- 需要 Claude Code CLI 在 `PATH` 上并已登录(`claude --version` 能运行,打开 `claude` 不会要求登录),以及 dsh 0.2(0.2.0-rc.1 或更新版本)。dsh 0.1.x 请按下方兼容性表格安装对应的 npm 标签。别的都不需要:没有 API key,没有 Node 构建步骤。
62
+ 需要 Claude Code CLI 在 `PATH` 上并已登录(`claude --version` 能运行,打开 `claude` 不会要求登录),以及 dsh 0.2(0.2.2-alpha.2 或更新版本)。dsh 0.2.0 或 0.2.1 请安装 1.5.14(`dsh-oh-my-claude@dsh-0.2.1`);dsh 0.1.x 请按下方兼容性表格安装对应的 npm 标签。别的都不需要:没有 API key,没有 Node 构建步骤。
63
63
 
64
64
  **通过 dsh 的插件页面**,在 Web 应用或 DSH Desktop 中:
65
65
 
@@ -101,11 +101,13 @@ subagent-model-selection: # 让 dsh 子智能体也能使用 Claude Code
101
101
 
102
102
  ## 兼容性
103
103
 
104
- dsh 只发布预发行版,客户端 API 也会在版本之间变动,所以插件的每个版本都记录它面向的 dsh 范围和实际运行验证过的 dsh。"可运行于"是代码带有兼容分支的范围;"测试于"是发版时机器上安装的那个 dsh。更新提示会从 npm 读取最低 dsh 版本,低于它的机器不会收到该版本。
104
+ dsh 只发布预发行版,客户端 API 也会在版本之间变动,所以插件的每个版本都记录它面向的 dsh 范围和实际运行验证过的 dsh。"可运行于"是代码带有兼容分支的范围;"测试于"是发版时机器上安装的那个 dsh。更新提示会从 npm 读取最低 dsh 版本:低于它的机器不会收到更新命令,提示会改为写明该版本需要的 dsh。
105
105
 
106
106
  | 插件 | 可运行于 dsh | 测试于 dsh | npm 标签 |
107
107
  | --- | --- | --- | --- |
108
- | 1.5.13 | 0.2.0-rc.1 至 0.2.2-rc.1 | 0.2.2-rc.1 | `latest`、`dsh-0.2` |
108
+ | 1.6.0 | 0.2.2-alpha.2 至 0.2.2-rc.1 | 0.2.2-rc.1 | `latest` |
109
+ | 1.5.14 | 0.2.0-rc.1 至 0.2.2-rc.1 | 0.2.2-rc.1 | `dsh-0.2.1`、`dsh-0.2` |
110
+ | 1.5.13 | 0.2.0-rc.1 至 0.2.2-rc.1 | 0.2.2-rc.1 | 无,已由 1.5.14 取代 |
109
111
  | 1.5.12 | 0.2.0-rc.1 至 0.2.2-alpha.2 | 0.2.2-alpha.2 | 无,已由 1.5.13 取代 |
110
112
  | 1.5.11 | 0.2.0-rc.1 至 0.2.2-alpha.2 | 0.2.2-alpha.2 | 无,已由 1.5.12 取代 |
111
113
  | 1.5.10 | 0.2.0-rc.1 至 0.2.2-alpha.2 | 0.2.2-alpha.2 | 无,已由 1.5.11 取代 |
@@ -148,7 +150,7 @@ dsh 只发布预发行版,客户端 API 也会在版本之间变动,所以
148
150
  21. dsh 自己的目标和会话以往的每个目标,与 Claude Code 的目标和定时任务并列显示。[Tasks](https://github.com/lcestou/dsh-oh-my-claude/blob/main/docs/panel.md#tasks)
149
151
  22. Claude 工作时你插话发送的消息,在 Claude 读取之前可以编辑或移除,也可以合并为一条编辑。消息上的文件或图片会保留,只修改文字。编辑期间消息不会发出。“立即发送”会打断 Claude,把这条消息作为下一轮发出。[Steering](https://github.com/lcestou/dsh-oh-my-claude/blob/main/docs/how-it-works.md#dsh-tools-over-mcp)
150
152
  23. 向上滚动越过 Claude 的工作状态行(旋转图标、动词、数字)后,它会在输入框上方重复显示,回看一长轮时也不会错过 Claude 正在做的事。设置中有开关可关闭。[轮次状态](https://github.com/lcestou/dsh-oh-my-claude/blob/main/docs/how-it-works.md#turn-status)
151
- 24. 在回复中选中文本,即可将其引用到消息中,或作为旁问向 Claude 提问,不占用对话本身;问题留空时,Claude 会解释这段内容。你自己消息里的引用也会像 Claude 回复中的引用一样显示:缩进,左侧有强调色竖线。[旁问](https://github.com/lcestou/dsh-oh-my-claude/blob/main/docs/panel.md#asides)
153
+ 24. 在回复中选中文本,dsh 的浮层(dsh 0.2.2)会在「引用文本」旁多一个「提问」,手机上则显示在输入框上方的一行:把这段内容作为旁问向 Claude 提问,不占用对话本身;问题留空,Claude 会解释这段内容。[旁问](https://github.com/lcestou/dsh-oh-my-claude/blob/main/docs/panel.md#asides)
152
154
  25. 一轮结束后,标题处保留一行收尾,和终端里一样:`✻ 烘焙了 27s · 03:21 完成`。被你停止的一轮显示 `已中断 · 想让 Claude 改做什么?`。[轮次状态](https://github.com/lcestou/dsh-oh-my-claude/blob/main/docs/how-it-works.md#turn-status)
153
155
  26. 在 dsh 0.1.7 上,Claude 的工具调用显示为 dsh 自己的工具卡片,和其他提供方一样,文字在卡片之间实时输出。也可以在设置中切换回行内文本。[工具行](https://github.com/lcestou/dsh-oh-my-claude/blob/main/docs/configuration.md)
154
156
  27. 在工作区中新建会话时,会使用该工作区上次运行的 Claude 主机、模型和推理强度;没有记录的工作区则使用你选定的默认模型和推理强度。[按工作区记住模型](https://github.com/lcestou/dsh-oh-my-claude/blob/main/docs/panel.md#remember-model-per-workspace)
@@ -172,12 +174,26 @@ dsh 只发布预发行版,客户端 API 也会在版本之间变动,所以
172
174
 
173
175
  ```yaml
174
176
  permissionMode: dsh # 跟随会话的盾牌(默认),或固定为 CLI 的六种模式之一
175
- spawn: keeper # Claude 在 dsh 重启后继续运行(默认);node 或 dsh 则作为普通子进程
177
+ # spawn: node # 不设置:由下方的设置开关决定;设为 node 或 dsh 则以此为准
176
178
  sshHost: "" # "[user@]host" 通过 ssh 驱动另一台机器上的 claude
177
179
  ```
178
180
 
179
181
  每个键及其默认值见 [docs/configuration.md](https://github.com/lcestou/dsh-oh-my-claude/blob/main/docs/configuration.md)。
180
182
 
183
+ ### dsh 重启时保持 Claude 运行
184
+
185
+ 设置 → Oh My Claude 下的这个开关决定 Claude Code 的启动方式,默认开启。配置中的 `spawn: node` 或 `spawn: dsh` 会覆盖它并锁定开关;`spawn: keeper` 不会锁定。切换后,每个会话在下一个回合生效。
186
+
187
+ | | 开启(`keeper`) | 关闭(`dsh`) | `node`(仅限配置) |
188
+ |---|---|---|---|
189
+ | dsh 重启时正在进行的回合 | 继续运行;新的 dsh 重新接上并显示它做了什么 | 结束;重启约十秒后,会话会收到一条“dsh 在此回合进行中重启”的提示并继续 | 同关闭 |
190
+ | dsh 退出后仍在运行的进程 | Claude,直到它在没有 dsh 连接且没有输出的情况下经过 `processIdleMs`(30 分钟,最少 5 分钟) | 正常退出后没有:dsh 会结束 Claude 及它启动的一切 | dsh 结束时 Claude 也结束;它启动的进程不受追踪 |
191
+ | dsh 的环境变量 | 全部传递 | 除 `DSH_*` 外全部传递:dsh 的 subprocess 接口会过滤含 KEY、TOKEN、SECRET、PASSWORD 的变量名,插件会把它们传回 | 全部传递 |
192
+ | SSH 主机和远程工作区 | 远端的 `claude` 托管在该主机上,同样不受重启影响;上面的空闲时限对它无效,它会一直运行,直到有 dsh 重新接上或主机重启 | 远端的 `claude` 随 ssh 连接一起结束 | 同关闭 |
193
+ | 平台 | Linux 和 macOS;Windows 上为 `node` | 全部;dsh 未挂载 subprocess 接口时为 `node` | 全部 |
194
+
195
+ DSH Web 和 DSH Desktop 使用各自的 dsh profile,因此只会重新接上各自启动的 Claude 进程。在同一个 profile 目录上启动的两个 dsh 仍会共用它们。
196
+
181
197
  ## 远程主机和账号
182
198
 
183
199
  用不同的 `configDir` 把插件挂载两次,即可使用两个登录。在 设置 → Oh My Claude → 主机 中列出其他运行 dsh 和本插件的主机,并在它们之间切换。也可以给一台主机起个名字、填上 `user@host`,通过 SSH 驱动那里的 `claude`,远端只需要安装 CLI;Tailscale 和 WireGuard 对等节点会作为可选主机出现。详见 [docs/remote.md](https://github.com/lcestou/dsh-oh-my-claude/blob/main/docs/remote.md)。