dsh-ssh-tui 0.8.0 → 0.8.2-rc.1
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.md +150 -0
- package/README.en.md +74 -8
- package/README.md +451 -577
- package/docs/display-mode.md +122 -0
- package/docs/release-notes-0.7.4.md +91 -0
- package/docs/release-notes-0.8.0.md +56 -0
- package/docs/release-notes-0.8.1.md +79 -0
- package/docs/release-notes-0.8.2-rc.1.md +159 -0
- package/docs/remote-ops.md +51 -0
- package/docs/terminals.md +53 -0
- package/docs/windows.md +13 -0
- package/lib/approval-state.js +148 -0
- package/lib/approval-state.js.map +1 -0
- package/lib/attach.js +4 -4
- package/lib/attach.js.map +1 -1
- package/lib/auth-failure.js +74 -0
- package/lib/auth-failure.js.map +1 -1
- package/lib/color-depth.js +26 -0
- package/lib/color-depth.js.map +1 -1
- package/lib/commands.js +2 -0
- package/lib/commands.js.map +1 -1
- package/lib/copy-text.js +30 -8
- package/lib/copy-text.js.map +1 -1
- package/lib/dialogs.js +124 -0
- package/lib/dialogs.js.map +1 -1
- package/lib/display-mode.js +147 -0
- package/lib/display-mode.js.map +1 -0
- package/lib/display-sock.js +490 -35
- package/lib/display-sock.js.map +1 -1
- package/lib/footer-accents.js +28 -0
- package/lib/footer-accents.js.map +1 -0
- package/lib/footer-budget.js +328 -0
- package/lib/footer-budget.js.map +1 -0
- package/lib/footer-format.js +433 -0
- package/lib/footer-format.js.map +1 -0
- package/lib/footer-layout.js +407 -0
- package/lib/footer-layout.js.map +1 -0
- package/lib/footer-meters.js +185 -0
- package/lib/footer-meters.js.map +1 -0
- package/lib/footer.js +19 -561
- package/lib/footer.js.map +1 -1
- package/lib/glyph-measure.js +92 -0
- package/lib/glyph-measure.js.map +1 -0
- package/lib/i18n/en.js +83 -7
- package/lib/i18n/en.js.map +1 -1
- package/lib/i18n/zh.js +85 -7
- package/lib/i18n/zh.js.map +1 -1
- package/lib/index.js +73 -5
- package/lib/index.js.map +1 -1
- package/lib/paint.js +75 -17
- package/lib/paint.js.map +1 -1
- package/lib/picker.js +14 -13
- package/lib/picker.js.map +1 -1
- package/lib/plan-projection.js +291 -0
- package/lib/plan-projection.js.map +1 -0
- package/lib/plan.js +61 -11
- package/lib/plan.js.map +1 -1
- package/lib/platform.js +96 -0
- package/lib/platform.js.map +1 -1
- package/lib/question-state.js +83 -0
- package/lib/question-state.js.map +1 -0
- package/lib/representation.js +283 -0
- package/lib/representation.js.map +1 -0
- package/lib/screen.js +105 -0
- package/lib/screen.js.map +1 -0
- package/lib/selection.js +5 -3
- package/lib/selection.js.map +1 -1
- package/lib/session-blank.js +81 -0
- package/lib/session-blank.js.map +1 -0
- package/lib/session-list.js +102 -81
- package/lib/session-list.js.map +1 -1
- package/lib/startup.js +56 -0
- package/lib/startup.js.map +1 -1
- package/lib/stats.js +101 -3
- package/lib/stats.js.map +1 -1
- package/lib/subagent-model.js +8 -7
- package/lib/subagent-model.js.map +1 -1
- package/lib/term-text.js +436 -69
- package/lib/term-text.js.map +1 -1
- package/lib/terminal-input.js +132 -10
- package/lib/terminal-input.js.map +1 -1
- package/lib/theme.js +335 -0
- package/lib/theme.js.map +1 -0
- package/lib/throughput.js +305 -0
- package/lib/throughput.js.map +1 -0
- package/lib/tool-present.js +67 -15
- package/lib/tool-present.js.map +1 -1
- package/lib/tui.js +4186 -1133
- package/lib/tui.js.map +1 -1
- package/lib/types/approval-state.d.ts +75 -0
- package/lib/types/attach.d.ts +6 -2
- package/lib/types/auth-failure.d.ts +55 -0
- package/lib/types/color-depth.d.ts +21 -0
- package/lib/types/commands.d.ts +6 -0
- package/lib/types/copy-text.d.ts +18 -1
- package/lib/types/dialogs.d.ts +147 -1
- package/lib/types/display-mode.d.ts +99 -0
- package/lib/types/display-sock.d.ts +90 -0
- package/lib/types/footer-accents.d.ts +22 -0
- package/lib/types/footer-budget.d.ts +204 -0
- package/lib/types/footer-format.d.ts +221 -0
- package/lib/types/footer-layout.d.ts +292 -0
- package/lib/types/footer-meters.d.ts +151 -0
- package/lib/types/footer.d.ts +19 -269
- package/lib/types/glyph-measure.d.ts +41 -0
- package/lib/types/index.d.ts +13 -0
- package/lib/types/paint.d.ts +48 -0
- package/lib/types/plan-projection.d.ts +162 -0
- package/lib/types/plan.d.ts +18 -2
- package/lib/types/platform.d.ts +83 -0
- package/lib/types/question-state.d.ts +96 -0
- package/lib/types/representation.d.ts +498 -0
- package/lib/types/screen.d.ts +126 -0
- package/lib/types/session-blank.d.ts +51 -0
- package/lib/types/session-list.d.ts +34 -0
- package/lib/types/startup.d.ts +30 -0
- package/lib/types/stats.d.ts +64 -1
- package/lib/types/subagent-model.d.ts +7 -6
- package/lib/types/term-text.d.ts +100 -24
- package/lib/types/terminal-input.d.ts +37 -0
- package/lib/types/theme.d.ts +109 -0
- package/lib/types/throughput.d.ts +163 -0
- package/lib/types/tool-present.d.ts +43 -2
- package/lib/types/transcript-types.d.ts +63 -2
- package/lib/types/tui.d.ts +960 -12
- package/package.json +73 -67
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,150 @@
|
|
|
1
|
+
# CHANGELOG
|
|
2
|
+
|
|
3
|
+
面向用户的变更记录。每个版本的**发版说明**(含头等事、兼容矩阵与已知问题)在
|
|
4
|
+
`docs/release-notes-<version>.md`;本文件只记一行一条的变更,按版本倒序。
|
|
5
|
+
|
|
6
|
+
变更分类:**Added** / **Changed** / **Fixed** / **Removed** / **Docs** / **Internal**。
|
|
7
|
+
|
|
8
|
+
> 本文件随包发布(`package.json` → `files`),发版说明也在包里(`docs/release-notes-*.md`);
|
|
9
|
+
> 指向 `docs/decisions/`、`docs/plans/`、`docs/checkpoints.md` 的链接是**仓库内**文档,只有 GitHub 上可读。
|
|
10
|
+
|
|
11
|
+
---
|
|
12
|
+
|
|
13
|
+
## 0.8.2-rc.1 — 2026-10-03(候选版;本版本地已就位,未打 tag、未发布)
|
|
14
|
+
|
|
15
|
+
发版说明:[`docs/release-notes-0.8.2-rc.1.md`](release-notes-0.8.2-rc.1.md)。
|
|
16
|
+
|
|
17
|
+
B2("what deserves to exist")的六个阶段 B2.1 – B2.6 已完成并通过最终审计,本节汇总用户能看到的
|
|
18
|
+
部分。详细证据与冻结记录见 [`docs/checkpoints.md`](checkpoints.md) 与
|
|
19
|
+
[`docs/decisions/b2-architecture-decisions.md`](decisions/b2-architecture-decisions.md) §20。
|
|
20
|
+
|
|
21
|
+
### Added
|
|
22
|
+
|
|
23
|
+
- **报告是 Screen**:`/status`、`/help`、`/doctor`、`/subagents`、`/diag` 等报告不再写进转写、
|
|
24
|
+
不再改变历史窗口,翻页只重画正文区,Esc 回到原处。
|
|
25
|
+
- **计划 artifact 投影**:计划模式下的待办与评审从会话日志折叠出来;一份计划一行引用、一个 dock、
|
|
26
|
+
一个评审 Surface,resume 后身份一致。
|
|
27
|
+
- **工具卡片的审批状态**:卡片自己拥有 `waiting / approved / rejected / unknown`(以及来源:
|
|
28
|
+
live / policy / durable / inferred);不再有独立的审批行。
|
|
29
|
+
- **首启向导是 Screen**:9 步向导不再是"借工作区 composer 的对话框",中途 detach/reattach 不丢步骤,
|
|
30
|
+
也不再清空读者已经打了一半的草稿。
|
|
31
|
+
- **`npm run freeze`**:一条命令跑完 B2 的八条冻结不变量与七条退役路径扫描(CI 在 Linux 与
|
|
32
|
+
Windows 两条腿上各跑一次)。
|
|
33
|
+
- **`npm run bench`**:五个动作(流式 delta / 等待时钟 / 报告翻页 / 菜单移动 / 向导打字)的性能基线,
|
|
34
|
+
并断言这五个动作都不整屏重画。
|
|
35
|
+
|
|
36
|
+
### Changed
|
|
37
|
+
|
|
38
|
+
- **反馈分流**:控制面的确认去页脚(echo,最低优先级,直到下一次输入),警告/失败去身份行(notice),
|
|
39
|
+
只有会改变历史的事实才进转写([`docs/checkpoints.md`](checkpoints.md) B2.3b)。
|
|
40
|
+
- **`/copy` 语法**:`/copy` 或 `/copy reply` 复制模型最后一条回复(默认);`/copy highlight` 复制焦点卡片;
|
|
41
|
+
`/copy error` 复制最新的错误/诊断行。复制键保留"取不到焦点就退回回复"的语义。
|
|
42
|
+
- **工作区在方向键后的停留**:resume 进来不再从窗口中间开始滚动,直接停在最新内容。
|
|
43
|
+
|
|
44
|
+
### Fixed
|
|
45
|
+
|
|
46
|
+
- **工具卡内容有多行代码时会窜到输入区**。`bash` 的摘要就是命令行原文,所以 heredoc 会带着换行进入
|
|
47
|
+
卡片标题行;而单行裁剪器(`truncateToWidth`)保留 LF/CR,于是一"行"里含多个换行 —— 终端会因此换行,
|
|
48
|
+
而按绝对行号定位的帧随后把下面每一行都写错位,卡片内容落到输入框和页脚上,还会出现两段文字拼在同一行。
|
|
49
|
+
实测:31 行的一帧里有 11 行含裸换行;修复后为 0。
|
|
50
|
+
- **Windows Terminal 下输入法的预输入字符不再在处理中卡片那一行的最右边闪烁**。终端把 IME 预输入画在
|
|
51
|
+
光标处,而写一行会把光标留在该行文本末尾;跑一轮时实时区域每 tick 重画、且位于输入框上方,于是光标停在
|
|
52
|
+
处理中卡片上、预输入就闪在那里。现在除光标自己所在行外,每写一行都把光标交还输入框。
|
|
53
|
+
- **命令提示不再一直占着位置**:确认("已复制 412 字")与警告(命令失败)显示 6 秒后自动让位、恢复原来的
|
|
54
|
+
遥测行(提交仍会立即清掉);**"将在下个步骤生效"的排队提示例外** —— 它显示到那条消息真正被提交为止,
|
|
55
|
+
因为它是"你有话在排队"的唯一标记。
|
|
56
|
+
- **全新安装不再跳过配置向导**。前端拉起后台 Host 时永远带 `--resume=<id>`(连它刚生成的新 id 也带),
|
|
57
|
+
而首启判定把 `resume` 当成"这台机器配置过",于是**新机器永远不会自动出现向导**,也没有任何提示。
|
|
58
|
+
判定现在只看凭据存不存在。
|
|
59
|
+
- **裸 400 现在会说明它是什么**:网关拒收的是请求本身(不是 key),并给出这一族的上游记录与绕法
|
|
60
|
+
(`/effort off` 或换 messages 风味路线);**不自动重试**(实测这类失败成串出现,重发由读者决定)。
|
|
61
|
+
- 流式输出不再每个 tick 整屏重画(B2.2:live 区是投影,不是转写行)。
|
|
62
|
+
- 高亮的工具卡片不再把内容画进相邻卡片;处理中卡片遇到长内容不再折断成一行。
|
|
63
|
+
- 计划卡不再吃掉输入法的预输入字符(dock 高度不得超过工作区一半,光标行永远在屏)。
|
|
64
|
+
- resume 的历史回放不再逐帧重画(20k 事件从 51 帧 / 1.2 s 降到一次重建)。
|
|
65
|
+
- 部分命令执行后没有任何提示(页脚放不下的确认现在退到身份行显示)。
|
|
66
|
+
- 待办未收尾的提醒不再伪装成一条"计划转写引用"(B2 最终审计:`plan-row` → `plan-notice`)。
|
|
67
|
+
- **resume 进入时不再有一段黑屏(1–3 秒)**:前端先在备用屏打出"正在载入历史会话…",relay 接入时
|
|
68
|
+
宿主又写了一次 `?1049h` —— 终端已在备用屏时这个序列会**清屏**,而回放期间按 B2.4 不合成任何帧,
|
|
69
|
+
于是读者面对的是一块空白,直到日志重建完(实测 20k 事件:9.1 s 清屏、12.6 s 首帧,中间 3.5 s 全黑)。
|
|
70
|
+
这条"进屏"序列现在搭在第一帧上发出,与它要清出来的内容同一个 tick;没有东西要等的 reattach 行为不变。
|
|
71
|
+
(上一版试过相反的做法 —— 加载期间由宿主补画一行 —— 结果写进了 relay 的测速窗口,那版已回退。)
|
|
72
|
+
- **思考卡片的文字不再发白**:`reasoning` 角色是 `2;3`,只有属性 —— "暗"完全靠 faint,不实现 faint 的
|
|
73
|
+
终端(报告的 256 色终端)就退回**默认前景色**,与旁边的回复一样亮。四个调色板现在各自给出 muted 颜色
|
|
74
|
+
(default `90`,catppuccin / gruvbox 用各自 `md-muted` 的色,mono 仍然只用属性),属性保留给支持的终端。
|
|
75
|
+
- **状态行不再把"绘制节奏"当成"链路延迟"**:终端不回 `CSI 6n` 时(现场 `/diag`:Linux + xterm-256color
|
|
76
|
+
+ SSH,`探测 未知`),这一格显示的是**回退的绘制节奏** 160ms,读者无法分辨它和真实延迟。现在改为
|
|
77
|
+
`SSH ○○○○ 未测` / `n/a`;测到过的链路照旧显示测量值,绘制节奏仍留在 `/diag` 那一行(写明是"绘制")。
|
|
78
|
+
- **`q` / `Q` 真的能关掉报告**:`inspectClosesOn` 一直声明接受它们("全屏报告理应响应 q"),
|
|
79
|
+
但可打印字符的提示分支在它之前返回,于是这两个键只会打印"这是报告视图,按 Esc 返回"。
|
|
80
|
+
|
|
81
|
+
### Docs
|
|
82
|
+
|
|
83
|
+
- [`docs/release.md`](release.md) 新增"发布前人工门槛":Windows 实机清单、fresh-home 首启探针命令、
|
|
84
|
+
以及 `npm run freeze` / `npm run bench` 两条发版自检。
|
|
85
|
+
- [`docs/decisions/b2-architecture-decisions.md`](decisions/b2-architecture-decisions.md) §20 记录 B2 冻结:
|
|
86
|
+
八条不变量、七条退役路径、以及"表示的分类必须与它包裹的行一致"这条规则。
|
|
87
|
+
|
|
88
|
+
### Internal
|
|
89
|
+
|
|
90
|
+
- **链路验收补齐"带历史的 resume"**:`scripts/tui-rtt-probe.mjs` 现在有两个阶段——新会话(先慢后快的
|
|
91
|
+
链路)与**带历史的 resume**(探针自己写一份 20k 事件的持久化日志,回放期间不合成帧)。后者同时断言
|
|
92
|
+
三件事:读者画面上出现过加载行之后**不得再变空**、转写落地、chip 落在真实测量值而不是 `○○○○ 160ms`
|
|
93
|
+
占位。两条断言都做过变异校验(改回"接入即写"报 4 秒黑屏;关掉 RTT 应用报 chip 停在占位)。
|
|
94
|
+
- **`verify-batch.mjs` 不再把 SKIP 说成 PASS**:有步骤跳过时收尾为 `RESULT: INCOMPLETE`(exit 2),
|
|
95
|
+
与 `FAIL`(exit 1)分开;`link` 已加入验收步骤表(`--only link` 可单跑)。
|
|
96
|
+
- 表示管线:每条转写行都带 durability / class / destination;审计对未分类行、未知 destination、
|
|
97
|
+
live 源行与重复 primary 表示各自计数,四个数字都必须为 0。
|
|
98
|
+
- 退役并在 CI 上禁止复活:`dedicated` Surface 角色、onboarding 的对话框渲染路径、
|
|
99
|
+
`upsertPlanRow`(计划行的第二个写入者)、`ask_user_question` 的通用工具卡。
|
|
100
|
+
- **Windows 实机轮(2026-10-03)修掉五处探针缺陷,产品代码未改**:`verify-batch` 在 Windows 上
|
|
101
|
+
因 `spawn('npm')` 必然 `ENOENT`(改用 `$npm_execpath`);`tui-route-probe` 的 `/tmp` 字面量
|
|
102
|
+
(改 `os.tmpdir()`)与目录符号链接(Windows 改 junction);`footer-windows-probe` 补了**未测量
|
|
103
|
+
链路**档案并逐格断言时长槽(`未测` 而非 `160ms`);`tui-mock-probe` 的鼠标坐标改由真实终端网格
|
|
104
|
+
给出(此前从字节流解析 `ESC[<row>;1H`,ConPTY 下拼出伪行,拖选看起来偏了两格——**是探针缺陷,
|
|
105
|
+
不是选择缺陷**)。
|
|
106
|
+
- **新增 `scripts/tui-unmeasured-probe.mjs`**(管道父进程,进 `verify-batch` 与 CI):ConPTY 自己回
|
|
107
|
+
`CSI 6n`,所以"终端不回 DSR"这一格在 Windows 本机摸不到,而这个形状正是读者报过两次的那个。两条腿
|
|
108
|
+
分别断言 `SSH ○○○○ 未测`(绘制节奏只留在 `/diag`)与 `SSH ●●●● <n>ms`。
|
|
109
|
+
- **ConPTY 盲区改为显式 `SKIP:`**(不再是"读错就判红"):`tui-cut-probe` 的静默半场、
|
|
110
|
+
`tui-rtt-probe` 的慢链路半场、`tui-setup-probe`/`--line-mode` 的字节形状检查。SKIP 仍收尾
|
|
111
|
+
`INCOMPLETE`。真实 home 未配置时(会进配置向导)同样 `SKIP:` 而不是超时报红;
|
|
112
|
+
`verify-batch --home <dir>` 可把读 profile 的三步指向自建 home。
|
|
113
|
+
|
|
114
|
+
### 已知问题
|
|
115
|
+
|
|
116
|
+
- Windows / ConPTY **实机人工验收已完成**(2026-10-03,维护者逐条走过 12 项清单,结论见
|
|
117
|
+
[`docs/checkpoints.md`](checkpoints.md)「Windows 实机轮」):可自动化的部分由 `verify-batch --home
|
|
118
|
+
<dir>` 覆盖(12 PASS · 2 SKIP · 0 FAIL),**没有自动化、只能人眼的两目(输入法组合、多行中文粘贴)
|
|
119
|
+
已确认通过**。两处 `SKIP` 是覆盖边界、不是通过:ConPTY 自己回 `CSI 6n`,"慢链路"与"静默但没断连"
|
|
120
|
+
这两个形状它扮演不了(这两个形状在 Linux 腿上真跑)。
|
|
121
|
+
- fresh-home 首启有两条探针覆盖(`scripts/tui-setup-probe.mjs` 断言向导自动出现 + 第二次启动不再出现;
|
|
122
|
+
`scripts/probe-onboarding.mjs` 供工作区探针识别"这是首启"并 `SKIP:` 而不是误报),命令在
|
|
123
|
+
[`docs/release.md`](release.md)。只读 pnpm store 的沙箱建不出 home,那是环境限制,不是覆盖缺口。
|
|
124
|
+
- ~~`scripts/tui-drop-probe.mjs` 约 1/7 概率因自身的 `/status` 重试竞态误报~~ —— **本版已修**:
|
|
125
|
+
改为一次请求在飞、按每次请求的输出判定、并按"当前是否真有 Screen"决定关闭,连跑 20 次无失败。
|
|
126
|
+
- 打包:`npm pack --dry-run` 实测 **243 个文件 / 1.4 MB(tarball)/ 解包 4.2 MB**,CHANGELOG 随包发布;
|
|
127
|
+
无凭据、无 home、无 sqlite、无 scratch。
|
|
128
|
+
|
|
129
|
+
---
|
|
130
|
+
|
|
131
|
+
## 0.8.1 — 2026-09-30(`latest` + `next`)
|
|
132
|
+
|
|
133
|
+
发版说明:[`docs/release-notes-0.8.1.md`](release-notes-0.8.1.md)。
|
|
134
|
+
|
|
135
|
+
### Fixed
|
|
136
|
+
|
|
137
|
+
- 没有终端的进程(桌面版 Electron-as-Node、管道、cron)不再抛错退出,而是保持惰性:不取锁、
|
|
138
|
+
不装定时器、不查更新,记一行说明,退出码 0。
|
|
139
|
+
|
|
140
|
+
### Added
|
|
141
|
+
|
|
142
|
+
- `DSH_TUI_DISPLAY=stdio`(或 `--display stdio`):宿主自带终端控件时可以把 TUI 当子进程用,
|
|
143
|
+
画面走 stdout、按键走 stdin、尺寸由 `CSI 8 ; rows ; cols t` 报告。
|
|
144
|
+
|
|
145
|
+
---
|
|
146
|
+
|
|
147
|
+
## 0.8.0 — 2026-09-29(`next`,随后提升为 `latest`)
|
|
148
|
+
|
|
149
|
+
发版说明:[`docs/release-notes-0.8.0.md`](release-notes-0.8.0.md)。基线切到上游 `0.2.0-rc` 线
|
|
150
|
+
(桌面版 Harness 的基线),兼容窗口与 CI 腿随之上移。
|
package/README.en.md
CHANGED
|
@@ -47,7 +47,7 @@ dsh --profile tui
|
|
|
47
47
|
Current `dsh` requires `--profile` (`dsh plugin add …` errors without it).
|
|
48
48
|
Swap `tui` for another profile name.
|
|
49
49
|
|
|
50
|
-
**
|
|
50
|
+
**Which host line?** `0.8.1` is `latest` and supports the `0.2.0-rc` line (the desktop harness's baseline) as well as `0.1.7-rc`; older releases are refused by the launcher's version check. **0.1.5 and older hosts are no longer supported as of 0.8.0.**
|
|
51
51
|
|
|
52
52
|
**Updates must use `@latest`.** `dsh plugin` forwards the rest of the line to
|
|
53
53
|
pnpm in the profile directory. A bare `add dsh-ssh-tui` keeps the version
|
|
@@ -92,8 +92,13 @@ OSC 52 into your local clipboard; a tool card still expands on click; an SSH ses
|
|
|
92
92
|
into the local terminal and no longer warns that it cannot) · a reply is a selectable card too:
|
|
93
93
|
one `↑` on an empty input lands on the newest reply-or-card (marked `▶`, in screen order;
|
|
94
94
|
`Alt+4` selects the latest reply), `/copy` then takes that one as written rather than the
|
|
95
|
-
wrapped screen text, and `Enter` opens it full-screen · the
|
|
96
|
-
|
|
95
|
+
wrapped screen text, and `Enter` opens it full-screen · the status row answers five questions
|
|
96
|
+
in one order — link health, what is running, tokens per second, quota left, context used — and
|
|
97
|
+
degrades by dropping cells as the terminal narrows (`⚠` still opens `/doctor`; the install
|
|
98
|
+
warning outranks everything), and the row under it is *ordered* by priority and cut from the
|
|
99
|
+
right — `dir:… · search n/m · queued n · sub:…`, closed by `OpenCode-GO` or
|
|
100
|
+
`CommandCode-GOAT` on those two subscriptions, so a narrow terminal loses the least
|
|
101
|
+
load-bearing part first · the quota meter is on screen from the first frame and names
|
|
97
102
|
its window (`5Hr`/`1Wk`/`1Mo`, smallest window by default, `?%` with a 15-second retry until
|
|
98
103
|
a reading arrives) · `/mode` groups presets and filters with `/` · the compact view names
|
|
99
104
|
every changed file · tool diffs are line-level, emphasise only what changed, and go
|
|
@@ -101,6 +106,51 @@ side-by-side at 100 columns or more · `DSH_TUI_LINE_MODE=1` appends plain lines
|
|
|
101
106
|
readers and `tee` · `ssh-tui.keys` rebinds keys, refusing conflicts · `DSH_TUI_COLOR_DEPTH`
|
|
102
107
|
pins the palette (truecolor / 256 / 8 / none).
|
|
103
108
|
|
|
109
|
+
## Which host lines this covers
|
|
110
|
+
|
|
111
|
+
The plugin declares and tests **both `@deepseek-ai/dsh` lines in flight**:
|
|
112
|
+
|
|
113
|
+
| Host line | Status |
|
|
114
|
+
| --- | --- |
|
|
115
|
+
| `0.1.7-rc.1` / `0.1.7-rc.2` (`latest`) | declared compatible; CI runs the full real-PTY probe set on rc.2 and typecheck + unit suite on rc.1 |
|
|
116
|
+
| `0.2.0-rc.1` / `0.2.0-rc.2` (`next`, also the desktop app's baseline) | declared compatible; rc.2 is the default development line with the full probe set, rc.1 gets typecheck + suite |
|
|
117
|
+
| `0.1.5` and older | **unsupported as of 0.8.0**, with an explicit `incompatible` entry in `dshReleases` |
|
|
118
|
+
|
|
119
|
+
The declared window is `>=0.1.7-rc.1 <0.1.8 || >=0.2.0-rc.1 <0.2.1` (peer dependencies and `dshReleases`
|
|
120
|
+
state the same fact), and every release re-installs those versions in a clean tree and re-runs the types, the
|
|
121
|
+
suite and the real-PTY probes — not "no errors, so it probably works". Many terminal plugins on npm are still
|
|
122
|
+
stranded on the 0.1.5 line; few terminal UIs install on the 0.2.0-rc line at all, which is why the window is
|
|
123
|
+
maintained this tightly.
|
|
124
|
+
|
|
125
|
+
## A warning before the Desktop section
|
|
126
|
+
|
|
127
|
+
> ⚠ **Do not add this plugin to a Desktop (or `web`) profile.** It is not "installed but
|
|
128
|
+
> idle" — it crashes the application. The desktop host's command line belongs to the web
|
|
129
|
+
> app (it passes `--no-open`), and dsh does not arbitrate: every app plugin parses the
|
|
130
|
+
> same argv with *its own* grammar, and an unknown flag exits the process. From 0.8.2 the
|
|
131
|
+
> plugin's startup row declines a command line that is not its own (the desktop launcher,
|
|
132
|
+
> or a web app that has already taken over); 0.8.1 and earlier exited 1 with
|
|
133
|
+
> `error: unknown option '--no-open'`, and the app reported
|
|
134
|
+
> `dsh desktop host exited with 1` and died. If it is already in there, remove the four
|
|
135
|
+
> `ssh-tui-*` rows from `profiles\desktop\cordis.patch.yml` (or restore that file from a
|
|
136
|
+
> backup) and the application works again.
|
|
137
|
+
|
|
138
|
+
## Desktop Harness users, read this first
|
|
139
|
+
|
|
140
|
+
**The official desktop app (<https://www.deepseek.com/harness/>) does not need this plugin** — use its own UI
|
|
141
|
+
or `dsh web`. This plugin is a *terminal* UI and must run on a real TTY; the launcher the desktop app puts on
|
|
142
|
+
your PATH (`DeepSeek Harness.exe` with `ELECTRON_RUN_AS_NODE`) is a GUI-subsystem process with no console, so
|
|
143
|
+
`dsh --profile tui` cannot start under it. For a terminal session, install the npm CLI:
|
|
144
|
+
|
|
145
|
+
```bash
|
|
146
|
+
npm i -g @deepseek-ai/dsh # a real console runtime
|
|
147
|
+
dsh --profile tui # from a terminal or an SSH session
|
|
148
|
+
```
|
|
149
|
+
|
|
150
|
+
**Under the desktop app this plugin stays inert rather than failing**: it logs one "inactive here" line through `ctx.logger` and mounts nothing (no locks, no timers, no update check), so the desktop never shows a failed plugin and cannot be broken by it. A profile that would rather fail loudly can set `requireTerminal: true`.
|
|
151
|
+
|
|
152
|
+
The full diagnosis, both desktop defects, the strategy and a copy-paste-ready upstream issue are in [`docs/desktop.md`](docs/desktop.md) and [`docs/upstream-desktop-report.md`](docs/upstream-desktop-report.md).
|
|
153
|
+
|
|
104
154
|
## Requirements
|
|
105
155
|
|
|
106
156
|
- Node.js >= 22.19
|
|
@@ -411,6 +461,8 @@ You can reopen the wizard at any time with:
|
|
|
411
461
|
| `/find [kind] query` | search and jump to the full matching message (`thinking` `plan` `subagent` `reply` `prompt` `tool`), which is also selected. `Ctrl+/` or `Alt+/` opens it |
|
|
412
462
|
| `/copy` | copy the selected card or reply **as written** to the local clipboard (latest reply if none is selected; OSC 52). The selection survives, so pressing it twice copies the same thing. Inside a full view the copy key (`Ctrl+Shift+C`) takes **the body on screen** — a tool body, a changes diff, or the reply as written — and the overlay echoes the confirmation |
|
|
413
463
|
| `/retryauth [on\|off]` | auto-retry once when the *provider* rejects a request (HTTP 401/403 while a local credential is configured); off by default. The three-step diagnosis is in [`docs/remote-ops.md`](docs/remote-ops.md) §4.8 |
|
|
464
|
+
| `/theme [name]` | palette: `default` / `catppuccin` / `gruvbox` / `mono` (emits no colour at all — bold, dim and underline carry the differences). `/theme` lists them and marks the current one; the choice is remembered, and `DSH_TUI_THEME` overrides it for one launch |
|
|
465
|
+
| Question dialog | ↑/↓ moves the highlight and `●` marks what Enter will submit; in a multi-select, Space (or a digit/letter) ticks a row (`✓`), Enter submits the ticked set (or the highlighted row if none is ticked), Esc cancels |
|
|
414
466
|
| `Ctrl+G` / `Alt+N` | next search hit; `Alt+P` previous |
|
|
415
467
|
| `Esc` | drop selection → scroll to bottom → cancel the running turn |
|
|
416
468
|
| `Ctrl+C` | cancel the running turn; press twice when idle to exit |
|
|
@@ -429,11 +481,14 @@ model, and sends unrecognized shapes (`npm publish`, interpreter `-c`/`-e`)
|
|
|
429
481
|
to the subagent-model reviewer (user message + args/reason/sandbox; English
|
|
430
482
|
UI uses the English reviewer; `authorization=yes` required). `/approval
|
|
431
483
|
status` also reports how many AI reviews ran this session.
|
|
432
|
-
The
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
`/status` prints the same figures
|
|
484
|
+
The status row shows context occupancy as a capacity meter over the routed
|
|
485
|
+
model's context window (DSH `contextPressure`, provider-agnostic); the bands are
|
|
486
|
+
the harness's own pressure levels, so 80% turns the meter yellow and 95% red —
|
|
487
|
+
exactly where compaction starts warning.
|
|
488
|
+
`/status` prints the same figures, plus everything the row gave up: turns,
|
|
489
|
+
steps, input/output/cached tokens, the session total (with the accounting it
|
|
490
|
+
came from), model time, tool time, cache hit and the exact last-step and
|
|
491
|
+
running `tokens/sec`. Warnings fire near 80%/95%; idle
|
|
437
492
|
auto-`/compact` starts near 72% so recovery is not left to a mid-turn
|
|
438
493
|
overflow. `/compact` shows a spinning compact card and footer until it
|
|
439
494
|
finishes, then the tokens recovered. `Tab` completes, `Enter` runs.
|
|
@@ -857,8 +912,19 @@ src/i18n/ zh/en UI catalogs
|
|
|
857
912
|
```sh
|
|
858
913
|
npm install
|
|
859
914
|
npm run build
|
|
915
|
+
npm test
|
|
916
|
+
```
|
|
917
|
+
|
|
918
|
+
Two commands that do not ask "is anything broken" but "is anything still held":
|
|
919
|
+
|
|
920
|
+
```sh
|
|
921
|
+
npm run freeze # the B2 freeze: eight invariants + seven retired paths (unclassified / live source rows / …)
|
|
922
|
+
npm run bench # the perf baseline: stream / wait / report paging / menu move / wizard typing, all incremental
|
|
860
923
|
```
|
|
861
924
|
|
|
925
|
+
The release rules — including the two things CI cannot cover (a Windows machine, and a
|
|
926
|
+
first-run home) — are in [docs/release.md](docs/release.md) (Chinese).
|
|
927
|
+
|
|
862
928
|
## Privacy
|
|
863
929
|
|
|
864
930
|
All sessions, credentials, and settings live under `$DSH_HOME` (default
|