dsh-bash-terminal-ts 0.9.6-rc.4 → 0.9.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.md CHANGED
@@ -1,5 +1,27 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.9.6 (2026-11-29)
4
+
5
+ **R1 预设全屏蔽 + R2 终端历史回顾:本计划的完整落地。**
6
+
7
+ ### R1 预设全屏蔽(rc.1)
8
+
9
+ - `standard-win` 预设模板中官方 `tool-pwsh` 行从 `disabled: !!js process.platform !== 'win32'` 改为 `disabled: true`;`tool-bash` 行保持 `disabled: true`。注释块与 persona 的 `Shell tool routing` 行同步重写。`preset.yml` description / `agent-presets/README.md` 表行与段落同步。屏蔽属 per-preset:“少一个入口”、宿主 `bash-sandbox` / `pwsh-sandbox` 与 `ctx.shell` 接缝不动。
10
+
11
+ ### R2 `terminal {action:"history"}`(rc.2 → rc.4)
12
+
13
+ - **`src/history.ts`**(rc.2):`redactCommand` 与 `stripAnsi` 为安全基元;`parsePsReadLine` / `parseBashHistory` / `historyCandidates` / `readShellHistory` / `groupByCwd` 实现 shell 历史读取;`ScreenHistoryStore` 实现已关会话的 LRU + 可选落盘。仅依赖 `node:fs/promises` / `node:child_process` / `node:path` / `node:crypto`,六条兼容线行为一致。
14
+ - **工具接线**(rc.3):`src/terminal.ts` 新增 `action:"history"` 分支与 `source`/`pattern`/`cwd`/`limit` 四参数;`createTerminalRegistry(ctx, onRetire?)` 新第二参;既六动作行为完全不变。
15
+ - **配置闸门**(rc.3):`historyShell:false / volatile`、`historyEntries:20`、`historyMaxBytes:65536`、`historyPath:""` 四个新 Config 字段;`apply()` 创建 store 并 `ctx.effect` 拆卸。
16
+ - **屏幕采集**(rc.3):`webterminals/registry.ts` 开可选 `UiRegistryOptions.onRetire?(info, snapshot)`,`mount.ts` 透传。未注入时行为与旧版完全一致。
17
+ - **设置页**(rc.3):`client.tsx` 新增两行——「命令历史回顾」开关与「历史条数」输入;`locales.ts` 4 键 × 10 语。
18
+ - **测试与文档**(rc.4):`test/history.ts` 28 断言(脱敏 8 类 × 十行反例、五候选 shell、WSL fake-spawn、LRU 淘汰、截尾 flag、persist/load 往返、坏 JSON 容错);`test/terminal.ts` 开一个隔离的 `toolWithHistory`,四场景验证闸门、空存储、回读命中、参数校验;`README.md` 与 `README.en.md` 新增「终端历史回顾」节。`package.json` test 链接入 `test-dist/history.js`。
19
+
20
+ ### Phase 9(真机验收)与 API 冻结
21
+
22
+ - Phase 9(需 profile 装机 + 手动目测)与本仓 CI 无交集,已在 README 中列为“开 `historyShell` 后跑一次 `source:"shell"` + 一次 open→send→close→`source:"screen"`”。
23
+ - 本版本后 `history` 动作的 schema(`source`/`pattern`/`cwd`/`limit` 四字段与三值枚举)、`redactCommand` 正则集合、`ScreenHistoryStore` LRU 行为与落盘机制均冻结;后续补丁只修实际发现的小缺陷(rc 阶梯见 v0.9.7 / v0.9.8),新能力属 v0.10.0+ 独立计划。
24
+
3
25
  ## 0.9.6-rc.4 (2026-11-29)
4
26
 
5
27
  **R2 Phase 7+8:`terminal.js` 四场景断言 + README 两语新增「终端历史回顾」节。**
package/dsh.plugin.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "id": "dsh-bash-terminal-ts",
3
3
  "name": "dsh-bash-terminal-ts",
4
- "version": "0.9.6-rc.4",
4
+ "version": "0.9.6",
5
5
  "description": {
6
6
  "en": "One shell tool that runs commands through PowerShell, Git Bash, MSYS2, WSL or Niubash on Windows, plus an embedded terminal for the bottom dock with per-shell activation switches and a default-shell fallback chain.",
7
7
  "zh": "一个 shell 工具,可在 Windows 上通过 PowerShell / Git Bash / MSYS2 / WSL / Niubash 执行命令;另提供底部工作台的内嵌终端,支持按 shell 激活开关与默认 shell 回落链。",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dsh-bash-terminal-ts",
3
- "version": "0.9.6-rc.4",
3
+ "version": "0.9.6",
4
4
  "publishConfig": {
5
5
  "registry": "https://registry.npmjs.org",
6
6
  "tag": "latest"