dsh-tool-content-guard 1.0.1 → 1.0.2
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 +11 -0
- package/README.md +9 -13
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,17 @@
|
|
|
3
3
|
本文件记录 `dsh-tool-content-guard` 的对外变更。版本号语义:修 bug → patch,
|
|
4
4
|
行为/配置新增 → minor,不兼容的挂载点或默认行为变更 → major。
|
|
5
5
|
|
|
6
|
+
## [1.0.2] — 2026-10-13
|
|
7
|
+
|
|
8
|
+
文档整理(**无代码改动**):把发版流程从 README 里搬出去,集中到一份清单。
|
|
9
|
+
|
|
10
|
+
- README 的「发版(维护者)」节不再内嵌 tag 规则与命令,改为指向
|
|
11
|
+
**《Gitee + npm 发布操作清单》**(本机 `D:\DWork\Gitee+npm发布操作清单.md`),
|
|
12
|
+
只保留本插件特有的自检命令与发布物白名单;
|
|
13
|
+
- 该清单统一了所有插件的发布流程:版本号/CHANGELOG → 自检 → `npm pack --dry-run` →
|
|
14
|
+
提交**并打 annotated tag `vX.Y.Z`** → 推 `master` 与 tag → `npm publish` →
|
|
15
|
+
核对 tag 与 npm 的 shasum 一致;含 staged publishing 排错、peer 范围写法、LF 约定。
|
|
16
|
+
|
|
6
17
|
## [1.0.1] — 2026-10-13
|
|
7
18
|
|
|
8
19
|
文档同步版(**无代码改动**):让 npm 上的文档与仓库一致,并让 `master` 的 HEAD 有一个对应的发布 tag。
|
package/README.md
CHANGED
|
@@ -147,20 +147,16 @@ node D:\DWork\dsfix\verify-guard-vs-log.mjs # 末行 GUARD vs LOG: OK
|
|
|
147
147
|
|
|
148
148
|
## 发版(维护者)
|
|
149
149
|
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
# 2) 提交并推 Gitee(默认分支 master),**每次发版都要打 tag**
|
|
156
|
-
git add -A; git commit -m "release: v1.0.1"; git tag -a v1.0.1 -m "v1.0.1 — 一句话"
|
|
157
|
-
git push origin master --tags
|
|
158
|
-
# 3) 发 npm
|
|
159
|
-
npm publish
|
|
160
|
-
```
|
|
150
|
+
完整流程见 **《Gitee + npm 发布操作清单》**(本机 `D:\DWork\Gitee+npm发布操作清单.md`):
|
|
151
|
+
改版本号 + CHANGELOG → 跑自检 → `npm pack --dry-run` → 提交**并打 annotated tag `vX.Y.Z`** →
|
|
152
|
+
推 `master` 与 tag → `npm publish` → 核对 tag 与 npm 的 shasum 一致。
|
|
153
|
+
|
|
154
|
+
本插件自己的两点:
|
|
161
155
|
|
|
162
|
-
|
|
163
|
-
|
|
156
|
+
- 自检:`npm test`(35 项,末行必须 `CONTENT GUARD: OK`);
|
|
157
|
+
- 发布物白名单 = `package.json` 的 `files`:`cordis.patch.yml`、`index.js`、`locale`、
|
|
158
|
+
`test`、`icon.svg`、`CHANGELOG.md`,外加 npm 强制包含的 `README.md` / `LICENSE` /
|
|
159
|
+
`package.json`;`node_modules/`(本地 junction)与 `*.bak-*` 由 `.gitignore` 挡住。
|
|
164
160
|
|
|
165
161
|
### npm 发布会被分阶段(staged publishing)— 2026-10-13 实测
|
|
166
162
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dsh-tool-content-guard",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.2",
|
|
4
4
|
"description": "DSH 插件:host 侧兜底——把工具 content 里非字符串的 `text` 强制字符串化(默认),或在开发模式下直接把这次调用判失败。挂在官方扩展点 tools/post-execute,先让其它策略跑完再归一化,避免 `{\"type\":\"text\",\"text\":[…]}` 这种非法块把 DeepSeek Messages 请求打成 422(invalid type: sequence, expected a string),也避免它落进会话日志、毒掉整个会话。",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"icon": "./icon.svg",
|