@tanlinfeng/project-docs-workflow 2.1.0 → 2.2.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.
package/README.md CHANGED
@@ -65,7 +65,7 @@ npx --yes skills@latest add mattpocock/skills -g -y -a <agent> -s <name1> <name2
65
65
 
66
66
  ```json
67
67
  {
68
- "version": "2.1.0",
68
+ "version": "2.2.0",
69
69
  "target": "/home/me/.agents/skills",
70
70
  "updatedAt": "2026-10-12T05:24:36.386Z",
71
71
  "entries": {
@@ -95,6 +95,30 @@ npx @tanlinfeng/project-docs-workflow uninstall [--dir <path>] [--dry-run] [--fo
95
95
  - **收尾**:处理完成后删除清单文件本身;**不会**删除目标目录本身,其它文件与空目录保持不动。
96
96
  - **幂等**:没有可删项时打印友好提示并以退出码 0 结束。若**清单缺失**,会告警「无清单,尽力而为」,此时**仅**在 `project-docs-workflow` 存在时询问是否删除它,其余 skill 一律不动。
97
97
 
98
+ ## 用法示例
99
+
100
+ ```bash
101
+ # —— 安装 ——
102
+ npx @tanlinfeng/project-docs-workflow # 装到默认 ~/.agents/skills(轻量依赖)
103
+ npx @tanlinfeng/project-docs-workflow --dir ~/.config/opencode/skills
104
+ npx @tanlinfeng/project-docs-workflow --dry-run # 预演,不写入
105
+ npx @tanlinfeng/project-docs-workflow --force # 覆盖主 skill(依赖仍不覆盖)
106
+ npx @tanlinfeng/project-docs-workflow --with-matt-skills # 依赖改从上游装完整版(需 Node >= 22.20)
107
+ npx @tanlinfeng/project-docs-workflow --with-matt-skills --matt-agent opencode
108
+
109
+ # —— 检查依赖解析 ——
110
+ npx @tanlinfeng/project-docs-workflow check # 全部可解析退出 0,否则 1
111
+
112
+ # —— 卸载 ——
113
+ npx @tanlinfeng/project-docs-workflow uninstall --dry-run # 只出计划
114
+ npx @tanlinfeng/project-docs-workflow uninstall # 交互确认(默认否)
115
+ npx @tanlinfeng/project-docs-workflow uninstall --force # 非交互必传;只删本包安装的
116
+ npx @tanlinfeng/project-docs-workflow uninstall --dir ~/.config/opencode/skills --force
117
+ ```
118
+
119
+ - 交互式终端下、不带 `--with-matt-skills` 安装时,会**询问一次**是否装上游完整版(默认否);管道 / CI 不提示、不挂起。
120
+ - 卸载在非 TTY 下没有 `--force` 会**拒绝执行**(退出码 1);`--dry-run` 从不询问、从不写入。
121
+
98
122
  ## 直接复制(不使用 npm 安装器)
99
123
 
100
124
  也可以完全跳过安装器,手动把 `skills/` 下需要的内容复制进你的 skills 根目录:
@@ -161,3 +185,14 @@ Optionally, `--with-matt-skills` installs the **full upstream** versions of the
161
185
  You can also copy `skills/*` directly into your skills root (skip any existing directory name, never overwrite); copying just `skills/project-docs-workflow` works standalone thanks to the internal ref fallbacks.
162
186
 
163
187
  Resolution is two-level: use an installed skill by name if present, otherwise follow `references/deps/*.md` inside the skill. Version `2.x` aligns with template generation v2. Licensed MIT (see `LICENSE` and `NOTICE`).
188
+
189
+ **Examples**
190
+
191
+ ```bash
192
+ npx @tanlinfeng/project-docs-workflow # install (default ~/.agents/skills)
193
+ npx @tanlinfeng/project-docs-workflow --dir <path> --dry-run
194
+ npx @tanlinfeng/project-docs-workflow --with-matt-skills # full upstream deps (Node >= 22.20)
195
+ npx @tanlinfeng/project-docs-workflow check
196
+ npx @tanlinfeng/project-docs-workflow uninstall --dry-run
197
+ npx @tanlinfeng/project-docs-workflow uninstall --force # only removes what this package installed
198
+ ```
package/bin/install.js CHANGED
@@ -73,6 +73,14 @@ function usage() {
73
73
  " --matt-agent <name>",
74
74
  " 上游安装使用的 agent(默认 codex,落盘到其全局目录 ~/.agents/skills)",
75
75
  " -h, --help 显示本帮助",
76
+ "",
77
+ "示例:",
78
+ " project-docs-workflow # 安装到默认 ~/.agents/skills",
79
+ " project-docs-workflow --dir <path> --dry-run # 预演到指定目录(不写入)",
80
+ " project-docs-workflow --with-matt-skills # 依赖改从上游装完整版",
81
+ " project-docs-workflow check # 检查依赖解析状态",
82
+ " project-docs-workflow uninstall --dry-run # 卸载预演",
83
+ " project-docs-workflow uninstall --force # 非交互卸载(只删本包装的)",
76
84
  ].join("\n")
77
85
  );
78
86
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tanlinfeng/project-docs-workflow",
3
- "version": "2.1.0",
3
+ "version": "2.2.0",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },