@fitlab-ai/agent-infra 0.3.2 → 0.4.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.
Files changed (302) hide show
  1. package/README.md +18 -35
  2. package/README.zh-CN.md +18 -35
  3. package/lib/defaults.json +5 -12
  4. package/lib/init.js +9 -25
  5. package/lib/paths.js +3 -42
  6. package/lib/update.js +43 -32
  7. package/package.json +2 -1
  8. package/templates/.agents/QUICKSTART.md +17 -7
  9. package/templates/.agents/QUICKSTART.zh-CN.md +17 -7
  10. package/templates/.agents/README.md +21 -14
  11. package/templates/.agents/README.zh-CN.md +21 -14
  12. package/templates/.agents/skills/analyze-task/SKILL.md +7 -10
  13. package/templates/.agents/skills/analyze-task/SKILL.zh-CN.md +7 -9
  14. package/templates/.agents/skills/block-task/SKILL.md +9 -13
  15. package/templates/.agents/skills/block-task/SKILL.zh-CN.md +9 -12
  16. package/templates/.agents/skills/check-task/SKILL.md +4 -8
  17. package/templates/.agents/skills/check-task/SKILL.zh-CN.md +4 -6
  18. package/templates/.agents/skills/close-codescan/SKILL.md +1 -4
  19. package/templates/.agents/skills/close-codescan/SKILL.zh-CN.md +1 -3
  20. package/templates/.agents/skills/close-dependabot/SKILL.md +1 -4
  21. package/templates/.agents/skills/close-dependabot/SKILL.zh-CN.md +1 -3
  22. package/templates/.agents/skills/commit/SKILL.md +26 -198
  23. package/templates/.agents/skills/commit/SKILL.zh-CN.md +26 -197
  24. package/templates/.agents/skills/commit/reference/commit-message.md +60 -0
  25. package/templates/.agents/skills/commit/reference/commit-message.zh-CN.md +60 -0
  26. package/templates/.agents/skills/commit/reference/copyright-check.md +39 -0
  27. package/templates/.agents/skills/commit/reference/copyright-check.zh-CN.md +39 -0
  28. package/templates/.agents/skills/commit/reference/task-status-update.md +88 -0
  29. package/templates/.agents/skills/commit/reference/task-status-update.zh-CN.md +88 -0
  30. package/templates/.agents/skills/complete-task/SKILL.md +8 -13
  31. package/templates/.agents/skills/complete-task/SKILL.zh-CN.md +8 -11
  32. package/templates/.agents/skills/create-issue/SKILL.md +32 -251
  33. package/templates/.agents/skills/create-issue/SKILL.zh-CN.md +33 -252
  34. package/templates/.agents/skills/create-issue/reference/label-and-type.md +77 -0
  35. package/templates/.agents/skills/create-issue/reference/label-and-type.zh-CN.md +77 -0
  36. package/templates/.agents/skills/create-issue/reference/template-matching.md +45 -0
  37. package/templates/.agents/skills/create-issue/reference/template-matching.zh-CN.md +45 -0
  38. package/templates/.agents/skills/create-pr/SKILL.md +33 -224
  39. package/templates/.agents/skills/create-pr/SKILL.zh-CN.md +32 -222
  40. package/templates/.agents/skills/create-pr/reference/branch-strategy.md +29 -0
  41. package/templates/.agents/skills/create-pr/reference/branch-strategy.zh-CN.md +29 -0
  42. package/templates/.agents/skills/create-pr/reference/pr-body-template.md +86 -0
  43. package/templates/.agents/skills/create-pr/reference/pr-body-template.zh-CN.md +86 -0
  44. package/templates/.agents/skills/create-release-note/SKILL.md +10 -13
  45. package/templates/.agents/skills/create-release-note/SKILL.zh-CN.md +10 -12
  46. package/templates/.agents/skills/create-task/SKILL.md +5 -8
  47. package/templates/.agents/skills/create-task/SKILL.zh-CN.md +5 -7
  48. package/templates/.agents/skills/implement-task/SKILL.md +48 -178
  49. package/templates/.agents/skills/implement-task/SKILL.zh-CN.md +44 -172
  50. package/templates/.agents/skills/implement-task/reference/implementation-rules.md +58 -0
  51. package/templates/.agents/skills/implement-task/reference/implementation-rules.zh-CN.md +58 -0
  52. package/templates/.agents/skills/implement-task/reference/report-template.md +63 -0
  53. package/templates/.agents/skills/implement-task/reference/report-template.zh-CN.md +63 -0
  54. package/templates/.agents/skills/import-codescan/SKILL.md +2 -5
  55. package/templates/.agents/skills/import-codescan/SKILL.zh-CN.md +2 -4
  56. package/templates/.agents/skills/import-dependabot/SKILL.md +4 -7
  57. package/templates/.agents/skills/import-dependabot/SKILL.zh-CN.md +4 -6
  58. package/templates/.agents/skills/import-issue/SKILL.md +6 -8
  59. package/templates/.agents/skills/import-issue/SKILL.zh-CN.md +6 -8
  60. package/templates/.agents/skills/init-labels/SKILL.md +1 -4
  61. package/templates/.agents/skills/init-labels/SKILL.zh-CN.md +1 -4
  62. package/templates/.agents/skills/init-milestones/SKILL.md +1 -3
  63. package/templates/.agents/skills/init-milestones/SKILL.zh-CN.md +1 -3
  64. package/templates/.agents/skills/plan-task/SKILL.md +7 -11
  65. package/templates/.agents/skills/plan-task/SKILL.zh-CN.md +7 -9
  66. package/templates/.agents/skills/refine-task/SKILL.md +38 -162
  67. package/templates/.agents/skills/refine-task/SKILL.zh-CN.md +36 -158
  68. package/templates/.agents/skills/refine-task/reference/fix-workflow.md +76 -0
  69. package/templates/.agents/skills/refine-task/reference/fix-workflow.zh-CN.md +76 -0
  70. package/templates/.agents/skills/refine-task/reference/report-template.md +38 -0
  71. package/templates/.agents/skills/refine-task/reference/report-template.zh-CN.md +38 -0
  72. package/templates/.agents/skills/refine-title/SKILL.md +1 -4
  73. package/templates/.agents/skills/refine-title/SKILL.zh-CN.md +1 -3
  74. package/templates/.agents/skills/release/SKILL.md +58 -19
  75. package/templates/.agents/skills/release/SKILL.zh-CN.md +58 -18
  76. package/templates/.agents/skills/review-task/SKILL.md +37 -239
  77. package/templates/.agents/skills/review-task/SKILL.zh-CN.md +37 -238
  78. package/templates/.agents/skills/review-task/reference/output-templates.md +72 -0
  79. package/templates/.agents/skills/review-task/reference/output-templates.zh-CN.md +72 -0
  80. package/templates/.agents/skills/review-task/reference/report-template.md +63 -0
  81. package/templates/.agents/skills/review-task/reference/report-template.zh-CN.md +63 -0
  82. package/templates/.agents/skills/review-task/reference/review-criteria.md +24 -0
  83. package/templates/.agents/skills/review-task/reference/review-criteria.zh-CN.md +24 -0
  84. package/templates/.agents/skills/sync-issue/SKILL.md +32 -490
  85. package/templates/.agents/skills/sync-issue/SKILL.zh-CN.md +33 -490
  86. package/templates/.agents/skills/sync-issue/reference/comment-publish.md +88 -0
  87. package/templates/.agents/skills/sync-issue/reference/comment-publish.zh-CN.md +88 -0
  88. package/templates/.agents/skills/sync-issue/reference/delivery-detection.md +42 -0
  89. package/templates/.agents/skills/sync-issue/reference/delivery-detection.zh-CN.md +42 -0
  90. package/templates/.agents/skills/sync-issue/reference/label-sync.md +63 -0
  91. package/templates/.agents/skills/sync-issue/reference/label-sync.zh-CN.md +63 -0
  92. package/templates/.agents/skills/sync-issue/reference/milestone-sync.md +37 -0
  93. package/templates/.agents/skills/sync-issue/reference/milestone-sync.zh-CN.md +37 -0
  94. package/templates/.agents/skills/sync-pr/SKILL.md +25 -287
  95. package/templates/.agents/skills/sync-pr/SKILL.zh-CN.md +29 -291
  96. package/templates/.agents/skills/sync-pr/reference/comment-publish.md +82 -0
  97. package/templates/.agents/skills/sync-pr/reference/comment-publish.zh-CN.md +82 -0
  98. package/templates/.agents/skills/sync-pr/reference/delivery-detection.md +54 -0
  99. package/templates/.agents/skills/sync-pr/reference/delivery-detection.zh-CN.md +54 -0
  100. package/templates/.agents/skills/test/SKILL.md +1 -3
  101. package/templates/.agents/skills/test/SKILL.zh-CN.md +1 -3
  102. package/templates/.agents/skills/test-integration/SKILL.md +1 -4
  103. package/templates/.agents/skills/test-integration/SKILL.zh-CN.md +1 -3
  104. package/templates/.agents/skills/update-agent-infra/SKILL.md +7 -11
  105. package/templates/.agents/skills/update-agent-infra/SKILL.zh-CN.md +7 -9
  106. package/templates/.agents/skills/update-agent-infra/scripts/sync-templates.js +59 -118
  107. package/templates/.agents/skills/upgrade-dependency/SKILL.md +1 -4
  108. package/templates/.agents/skills/upgrade-dependency/SKILL.zh-CN.md +1 -3
  109. package/templates/.agents/templates/handoff.md +1 -1
  110. package/templates/.agents/templates/handoff.zh-CN.md +1 -1
  111. package/templates/.agents/workflows/bug-fix.yaml +71 -71
  112. package/templates/.agents/workflows/bug-fix.zh-CN.yaml +1 -1
  113. package/templates/.agents/workflows/feature-development.yaml +71 -71
  114. package/templates/.agents/workflows/feature-development.zh-CN.yaml +1 -1
  115. package/templates/.agents/workflows/refactoring.yaml +76 -76
  116. package/templates/.agents/workflows/refactoring.zh-CN.yaml +1 -1
  117. package/templates/{.agent-workspace → .agents/workspace}/README.md +1 -1
  118. package/templates/{.agent-workspace → .agents/workspace}/README.zh-CN.md +1 -1
  119. package/templates/.claude/CLAUDE.md +14 -52
  120. package/templates/.claude/CLAUDE.zh-CN.md +14 -52
  121. package/templates/.claude/commands/analyze-task.md +1 -1
  122. package/templates/.claude/commands/analyze-task.zh-CN.md +1 -1
  123. package/templates/.claude/commands/block-task.md +2 -1
  124. package/templates/.claude/commands/block-task.zh-CN.md +2 -1
  125. package/templates/.claude/commands/check-task.md +2 -1
  126. package/templates/.claude/commands/check-task.zh-CN.md +2 -1
  127. package/templates/.claude/commands/close-codescan.md +2 -1
  128. package/templates/.claude/commands/close-codescan.zh-CN.md +2 -1
  129. package/templates/.claude/commands/close-dependabot.md +2 -1
  130. package/templates/.claude/commands/close-dependabot.zh-CN.md +2 -1
  131. package/templates/.claude/commands/commit.md +1 -1
  132. package/templates/.claude/commands/commit.zh-CN.md +1 -1
  133. package/templates/.claude/commands/complete-task.md +1 -1
  134. package/templates/.claude/commands/complete-task.zh-CN.md +1 -1
  135. package/templates/.claude/commands/create-issue.md +1 -1
  136. package/templates/.claude/commands/create-issue.zh-CN.md +1 -1
  137. package/templates/.claude/commands/create-pr.md +1 -1
  138. package/templates/.claude/commands/create-pr.zh-CN.md +1 -1
  139. package/templates/.claude/commands/create-release-note.md +2 -1
  140. package/templates/.claude/commands/create-release-note.zh-CN.md +2 -1
  141. package/templates/.claude/commands/create-task.md +1 -1
  142. package/templates/.claude/commands/create-task.zh-CN.md +1 -1
  143. package/templates/.claude/commands/implement-task.md +1 -1
  144. package/templates/.claude/commands/implement-task.zh-CN.md +1 -1
  145. package/templates/.claude/commands/import-codescan.md +1 -0
  146. package/templates/.claude/commands/import-codescan.zh-CN.md +2 -1
  147. package/templates/.claude/commands/import-dependabot.md +1 -0
  148. package/templates/.claude/commands/import-dependabot.zh-CN.md +2 -1
  149. package/templates/.claude/commands/import-issue.md +1 -1
  150. package/templates/.claude/commands/import-issue.zh-CN.md +1 -1
  151. package/templates/.claude/commands/init-labels.md +1 -0
  152. package/templates/.claude/commands/init-labels.zh-CN.md +2 -1
  153. package/templates/.claude/commands/init-milestones.md +2 -1
  154. package/templates/.claude/commands/init-milestones.zh-CN.md +2 -1
  155. package/templates/.claude/commands/plan-task.md +1 -1
  156. package/templates/.claude/commands/plan-task.zh-CN.md +1 -1
  157. package/templates/.claude/commands/refine-task.zh-CN.md +1 -1
  158. package/templates/.claude/commands/refine-title.md +2 -1
  159. package/templates/.claude/commands/refine-title.zh-CN.md +2 -1
  160. package/templates/.claude/commands/release.md +2 -1
  161. package/templates/.claude/commands/release.zh-CN.md +2 -1
  162. package/templates/.claude/commands/review-task.md +1 -1
  163. package/templates/.claude/commands/review-task.zh-CN.md +1 -1
  164. package/templates/.claude/commands/sync-issue.md +1 -1
  165. package/templates/.claude/commands/sync-issue.zh-CN.md +1 -1
  166. package/templates/.claude/commands/sync-pr.md +1 -1
  167. package/templates/.claude/commands/sync-pr.zh-CN.md +1 -1
  168. package/templates/.claude/commands/test-integration.md +2 -1
  169. package/templates/.claude/commands/test-integration.zh-CN.md +2 -1
  170. package/templates/.claude/commands/test.md +1 -1
  171. package/templates/.claude/commands/test.zh-CN.md +1 -1
  172. package/templates/.claude/commands/update-agent-infra.md +2 -1
  173. package/templates/.claude/commands/update-agent-infra.zh-CN.md +2 -1
  174. package/templates/.claude/commands/upgrade-dependency.md +2 -1
  175. package/templates/.claude/commands/upgrade-dependency.zh-CN.md +2 -1
  176. package/templates/.claude/hooks/check-version-format.sh +44 -0
  177. package/templates/.claude/settings.json +14 -0
  178. package/templates/.gemini/commands/_project_/analyze-task.toml +1 -1
  179. package/templates/.gemini/commands/_project_/analyze-task.zh-CN.toml +1 -1
  180. package/templates/.gemini/commands/_project_/block-task.toml +1 -1
  181. package/templates/.gemini/commands/_project_/block-task.zh-CN.toml +1 -1
  182. package/templates/.gemini/commands/_project_/check-task.toml +1 -1
  183. package/templates/.gemini/commands/_project_/check-task.zh-CN.toml +1 -1
  184. package/templates/.gemini/commands/_project_/close-codescan.toml +1 -1
  185. package/templates/.gemini/commands/_project_/close-codescan.zh-CN.toml +1 -1
  186. package/templates/.gemini/commands/_project_/close-dependabot.toml +1 -1
  187. package/templates/.gemini/commands/_project_/close-dependabot.zh-CN.toml +1 -1
  188. package/templates/.gemini/commands/_project_/commit.toml +1 -1
  189. package/templates/.gemini/commands/_project_/commit.zh-CN.toml +1 -1
  190. package/templates/.gemini/commands/_project_/complete-task.toml +1 -1
  191. package/templates/.gemini/commands/_project_/complete-task.zh-CN.toml +1 -1
  192. package/templates/.gemini/commands/_project_/create-issue.zh-CN.toml +1 -1
  193. package/templates/.gemini/commands/_project_/create-pr.toml +1 -1
  194. package/templates/.gemini/commands/_project_/create-pr.zh-CN.toml +1 -1
  195. package/templates/.gemini/commands/_project_/create-release-note.toml +1 -1
  196. package/templates/.gemini/commands/_project_/create-release-note.zh-CN.toml +1 -1
  197. package/templates/.gemini/commands/_project_/create-task.toml +1 -1
  198. package/templates/.gemini/commands/_project_/create-task.zh-CN.toml +1 -1
  199. package/templates/.gemini/commands/_project_/implement-task.toml +1 -1
  200. package/templates/.gemini/commands/_project_/implement-task.zh-CN.toml +1 -1
  201. package/templates/.gemini/commands/_project_/import-codescan.zh-CN.toml +1 -1
  202. package/templates/.gemini/commands/_project_/import-dependabot.zh-CN.toml +1 -1
  203. package/templates/.gemini/commands/_project_/import-issue.toml +1 -1
  204. package/templates/.gemini/commands/_project_/import-issue.zh-CN.toml +1 -1
  205. package/templates/.gemini/commands/_project_/init-labels.zh-CN.toml +1 -1
  206. package/templates/.gemini/commands/_project_/init-milestones.toml +1 -1
  207. package/templates/.gemini/commands/_project_/init-milestones.zh-CN.toml +1 -1
  208. package/templates/.gemini/commands/_project_/plan-task.toml +1 -1
  209. package/templates/.gemini/commands/_project_/plan-task.zh-CN.toml +1 -1
  210. package/templates/.gemini/commands/_project_/refine-task.zh-CN.toml +1 -1
  211. package/templates/.gemini/commands/_project_/refine-title.toml +1 -1
  212. package/templates/.gemini/commands/_project_/refine-title.zh-CN.toml +1 -1
  213. package/templates/.gemini/commands/_project_/release.toml +1 -1
  214. package/templates/.gemini/commands/_project_/release.zh-CN.toml +1 -1
  215. package/templates/.gemini/commands/_project_/review-task.toml +1 -1
  216. package/templates/.gemini/commands/_project_/review-task.zh-CN.toml +1 -1
  217. package/templates/.gemini/commands/_project_/sync-issue.toml +1 -1
  218. package/templates/.gemini/commands/_project_/sync-issue.zh-CN.toml +1 -1
  219. package/templates/.gemini/commands/_project_/sync-pr.toml +1 -1
  220. package/templates/.gemini/commands/_project_/sync-pr.zh-CN.toml +1 -1
  221. package/templates/.gemini/commands/_project_/test-integration.toml +1 -1
  222. package/templates/.gemini/commands/_project_/test-integration.zh-CN.toml +1 -1
  223. package/templates/.gemini/commands/_project_/test.toml +1 -1
  224. package/templates/.gemini/commands/_project_/test.zh-CN.toml +1 -1
  225. package/templates/.gemini/commands/_project_/update-agent-infra.toml +1 -1
  226. package/templates/.gemini/commands/_project_/update-agent-infra.zh-CN.toml +1 -1
  227. package/templates/.gemini/commands/_project_/upgrade-dependency.toml +1 -1
  228. package/templates/.gemini/commands/_project_/upgrade-dependency.zh-CN.toml +1 -1
  229. package/templates/.github/hooks/check-version-format.sh +29 -0
  230. package/templates/.github/hooks/pre-commit +8 -0
  231. package/templates/.opencode/COMMAND_STYLE_GUIDE.md +6 -6
  232. package/templates/.opencode/COMMAND_STYLE_GUIDE.zh-CN.md +6 -6
  233. package/templates/.opencode/commands/analyze-task.md +1 -1
  234. package/templates/.opencode/commands/analyze-task.zh-CN.md +1 -1
  235. package/templates/.opencode/commands/block-task.md +1 -1
  236. package/templates/.opencode/commands/block-task.zh-CN.md +1 -1
  237. package/templates/.opencode/commands/check-task.md +1 -1
  238. package/templates/.opencode/commands/check-task.zh-CN.md +1 -1
  239. package/templates/.opencode/commands/close-codescan.md +1 -1
  240. package/templates/.opencode/commands/close-codescan.zh-CN.md +1 -1
  241. package/templates/.opencode/commands/close-dependabot.md +1 -1
  242. package/templates/.opencode/commands/close-dependabot.zh-CN.md +1 -1
  243. package/templates/.opencode/commands/commit.md +1 -1
  244. package/templates/.opencode/commands/commit.zh-CN.md +1 -1
  245. package/templates/.opencode/commands/complete-task.md +1 -1
  246. package/templates/.opencode/commands/complete-task.zh-CN.md +1 -1
  247. package/templates/.opencode/commands/create-issue.zh-CN.md +1 -1
  248. package/templates/.opencode/commands/create-pr.md +1 -1
  249. package/templates/.opencode/commands/create-pr.zh-CN.md +1 -1
  250. package/templates/.opencode/commands/create-release-note.md +1 -1
  251. package/templates/.opencode/commands/create-release-note.zh-CN.md +1 -1
  252. package/templates/.opencode/commands/create-task.md +1 -1
  253. package/templates/.opencode/commands/create-task.zh-CN.md +1 -1
  254. package/templates/.opencode/commands/implement-task.md +1 -1
  255. package/templates/.opencode/commands/implement-task.zh-CN.md +1 -1
  256. package/templates/.opencode/commands/import-codescan.zh-CN.md +1 -1
  257. package/templates/.opencode/commands/import-dependabot.zh-CN.md +1 -1
  258. package/templates/.opencode/commands/import-issue.md +1 -1
  259. package/templates/.opencode/commands/import-issue.zh-CN.md +1 -1
  260. package/templates/.opencode/commands/init-labels.zh-CN.md +1 -1
  261. package/templates/.opencode/commands/init-milestones.md +1 -1
  262. package/templates/.opencode/commands/init-milestones.zh-CN.md +1 -1
  263. package/templates/.opencode/commands/plan-task.md +1 -1
  264. package/templates/.opencode/commands/plan-task.zh-CN.md +1 -1
  265. package/templates/.opencode/commands/refine-task.zh-CN.md +1 -1
  266. package/templates/.opencode/commands/refine-title.md +1 -1
  267. package/templates/.opencode/commands/refine-title.zh-CN.md +1 -1
  268. package/templates/.opencode/commands/release.md +1 -1
  269. package/templates/.opencode/commands/release.zh-CN.md +1 -1
  270. package/templates/.opencode/commands/review-task.md +1 -1
  271. package/templates/.opencode/commands/review-task.zh-CN.md +1 -1
  272. package/templates/.opencode/commands/sync-issue.md +1 -1
  273. package/templates/.opencode/commands/sync-issue.zh-CN.md +1 -1
  274. package/templates/.opencode/commands/sync-pr.md +1 -1
  275. package/templates/.opencode/commands/sync-pr.zh-CN.md +1 -1
  276. package/templates/.opencode/commands/test-integration.md +1 -1
  277. package/templates/.opencode/commands/test-integration.zh-CN.md +1 -1
  278. package/templates/.opencode/commands/test.md +1 -1
  279. package/templates/.opencode/commands/test.zh-CN.md +1 -1
  280. package/templates/.opencode/commands/update-agent-infra.md +1 -1
  281. package/templates/.opencode/commands/update-agent-infra.zh-CN.md +1 -1
  282. package/templates/.opencode/commands/upgrade-dependency.md +1 -1
  283. package/templates/.opencode/commands/upgrade-dependency.zh-CN.md +1 -1
  284. package/templates/AGENTS.md +11 -3
  285. package/templates/AGENTS.zh-CN.md +11 -3
  286. package/templates/.editorconfig +0 -15
  287. package/templates/.github/ISSUE_TEMPLATE/01_bug_report.yml +0 -149
  288. package/templates/.github/ISSUE_TEMPLATE/02_question.yml +0 -101
  289. package/templates/.github/ISSUE_TEMPLATE/03_feature_request.yml +0 -131
  290. package/templates/.github/ISSUE_TEMPLATE/04_documentation.yml +0 -165
  291. package/templates/.github/ISSUE_TEMPLATE/05_other.yml +0 -147
  292. package/templates/.github/ISSUE_TEMPLATE/config.yml +0 -11
  293. package/templates/.github/PULL_REQUEST_TEMPLATE.md +0 -123
  294. package/templates/.github/dependabot.yml +0 -17
  295. package/templates/.github/hooks/check-utf8-encoding.sh +0 -25
  296. package/templates/.github/release.yml +0 -27
  297. package/templates/.github/workflows/pr-title-check.yml +0 -42
  298. package/templates/.mailmap +0 -4
  299. package/templates/CONTRIBUTING.md +0 -126
  300. package/templates/CONTRIBUTING.zh-CN.md +0 -124
  301. package/templates/SECURITY.md +0 -131
  302. package/templates/SECURITY.zh-CN.md +0 -131
@@ -1,92 +1,52 @@
1
1
  ---
2
2
  name: refine-task
3
- description: >
4
- 处理代码审查反馈并修复审查中发现的问题。按优先级(Blocker -> Major -> Minor)修复。
5
- 仅处理审查中标记的问题,不添加额外变更。当用户要求修复审查问题时触发。参数:task-id。
3
+ description: "处理代码审查反馈并修复问题"
6
4
  ---
7
5
 
8
6
  # 修复审查问题
9
7
 
8
+ 修复审查发现的问题,并产出 `refinement.md` 或 `refinement-r{N}.md`。
9
+
10
10
  ## 行为边界 / 关键规则
11
11
 
12
- - 仅修复审查中标记的问题 —— 不要添加无关变更或额外的"改进"
13
- - 不要自动提交。绝不自动执行 `git commit` 或 `git add`
14
- - 执行本技能后,你**必须**立即更新 task.md 中的任务状态
12
+ - 只修复审查产物中记录的问题
13
+ - 绝不自动执行 `git add` 或 `git commit`
14
+ - 执行本技能后,你**必须**立即更新 task.md
15
15
 
16
16
  ## 执行步骤
17
17
 
18
18
  ### 1. 验证前置条件
19
19
 
20
- 检查必要文件:
21
- - `.agent-workspace/active/{task-id}/task.md` - 任务文件
20
+ 要求存在:
21
+ - `.agents/workspace/active/{task-id}/task.md`
22
22
  - 至少一个审查产物:`review.md` 或 `review-r{N}.md`
23
23
 
24
- 注意:`{task-id}` 格式为 `TASK-{yyyyMMdd-HHmmss}`,例如 `TASK-20260306-143022`
25
-
26
- 如果缺少 `task.md` 或没有任何审查产物,提示用户先完成前置步骤。
27
-
28
- 随后执行以下发现与校验:
29
- 1. 扫描任务目录中的审查产物文件(`review.md`、`review-r{N}.md`)
30
- 2. 取最高轮次的审查产物作为本次修复输入,记为 `{review-artifact}`
31
- 3. 扫描修复产物文件(`refinement.md`、`refinement-r{N}.md`)并确定本轮修复产物:
32
- - 如果不存在 `refinement.md` 且不存在 `refinement-r*.md` → 本轮为第 1 轮,产出 `refinement.md`
33
- - 如果存在 `refinement.md` 且不存在 `refinement-r*.md` → 本轮为第 2 轮,产出 `refinement-r2.md`
34
- - 如果存在 `refinement-r{N}.md` → 本轮为第 N+1 轮,产出 `refinement-r{N+1}.md`
35
- - 记录 `{refinement-round}` 和 `{refinement-artifact}`
36
- 4. 扫描实现报告文件(`implementation.md`、`implementation-r{N}.md`),取最高轮次作为修复上下文的 `{implementation-artifact}`
37
- - 记录 `{implementation-artifact}`
38
- 5. **一致性校验**:检查 `task.md` 的 `## 活动日志` 中最近一条 Code Review 记录的轮次号和文件名,是否与步骤 2 扫描到的最新审查产物匹配
24
+ 在前置检查阶段必须记录 `{review-artifact}`、`{refinement-round}`、`{refinement-artifact}`,并从最新实现报告中记录 `{implementation-artifact}`。
39
25
 
40
- Activity Log 记录与实际文件不匹配,立即停止并提示:
26
+ 同时校验 Activity Log 中最近一条 Code Review 记录;如果引用了不存在的文件,立即停止并输出:
41
27
  `Review artifact mismatch: Activity Log references {expected} but file not found. Please verify the review artifact exists.`
42
28
 
43
29
  ### 2. 阅读审查与实现上下文
44
30
 
45
- 仔细阅读步骤 1 中确定的最新审查产物 `{review-artifact}` 和实现产物 `{implementation-artifact}` 以理解:
46
- - 所有阻塞项(必须修复)
47
- - 所有主要问题(应该修复)
48
- - 次要问题(可选优化)
49
- - 审查者的建议和推荐
50
- - 当前实现和之前修复的上下文
51
-
52
- ### 3. 规划修复
53
-
54
- 分类并确定优先级:
55
- 1. **阻塞项优先**:必须解决所有阻塞项
56
- 2. **然后是主要问题**:处理所有主要问题
57
- 3. **最后是次要问题**:如有时间则处理(可选)
31
+ 在修改代码前先读取最新的 `{review-artifact}` `{implementation-artifact}`。
58
32
 
59
- 对于每个问题,确定:
60
- - 需要修改哪些文件
61
- - 具体要做哪些修改
62
- - 如何验证修复
33
+ ### 3. 规划并执行修复
63
34
 
64
- ### 4. 执行代码修复
35
+ Blocker -> Major -> Minor 的顺序处理,始终保持改动聚焦。
65
36
 
66
- 按优先级顺序修复问题:
37
+ > 详细修复流程、优先级和验证循环见 `reference/fix-workflow.md`。执行此步骤前先读取 `reference/fix-workflow.md`。
67
38
 
68
- **对于每个修复**:
69
- 1. 读取受影响的文件
70
- 2. 应用修复
71
- 3. 验证修复是否解决了审查意见
72
- 4. 运行相关测试
39
+ ### 4. 运行测试验证
73
40
 
74
- **修复原则**:
75
- - 仅修复标记的问题 —— 不要添加无关变更
76
- - 不要添加超出要求的额外"改进"
77
- - 保持变更最小化和聚焦
41
+ 修复后运行项目测试命令,并把修复范围限制在审查结论内。
78
42
 
79
- ### 5. 运行测试验证
43
+ ### 5. 编写修复报告
80
44
 
81
- 执行项目的测试命令。参考 `test` 技能获取项目特定的测试命令。
45
+ 创建 `.agents/workspace/active/{task-id}/{refinement-artifact}`。
82
46
 
83
- 确保修复后所有测试仍然通过。
47
+ > 报告结构和示例章节见 `reference/report-template.md`。写报告前先读取 `reference/report-template.md`。
84
48
 
85
- ### 6. 创建修复报告
86
-
87
- 创建 `.agent-workspace/active/{task-id}/{refinement-artifact}`。
88
-
89
- ### 7. 更新任务状态
49
+ ### 6. 更新任务状态
90
50
 
91
51
  获取当前时间:
92
52
 
@@ -94,115 +54,33 @@ description: >
94
54
  date "+%Y-%m-%d %H:%M:%S"
95
55
  ```
96
56
 
97
- 更新 `.agent-workspace/active/{task-id}/task.md`:
98
- - `current_step`:refinement
99
- - `assigned_to`:{当前 AI 代理}
100
- - `updated_at`:{当前时间}
101
- - 记录本轮修复产物:`{refinement-artifact}`(Round `{refinement-round}`)
102
- - **追加**到 `## Activity Log`(不要覆盖之前的记录):
103
- ```
104
- - {yyyy-MM-dd HH:mm:ss} — **Refinement (Round {N}, for {review-artifact})** by {agent} — Fixed {n} blockers, {n} major, {n} minor issues → {refinement-artifact}
105
- ```
106
-
107
- ### 8. 告知用户
108
-
109
- > **重要**:以下「下一步」中列出的所有 TUI 命令格式必须完整输出,不要只展示当前 AI 代理对应的格式。
110
-
111
- > **⚠️ 条件判断 — 在展示下面两个下一步之前,你必须先判断修复结果:**
112
- >
113
- > - 如果本轮修复了任何 `Blocker` 或 `Major` 问题,或改动影响核心逻辑/测试范围较广,**默认推荐**先执行「重新审查」
114
- > - 如果仅修复 `Minor` 问题,且变更范围很小、风险可控,才可以把「直接提交」作为可选项
115
- > - 如果仍有未修复的 `Blocker` 或 `Major`,**不要**暗示可以直接提交;应明确提示继续修复或重新审查
116
- >
117
- > **禁止把「直接提交」写成默认路径,除非你确认没有剩余高风险问题。**
118
-
119
- 输出格式:
120
- ```
121
- 任务 {task-id} 修复完成。
122
-
123
- 修复情况:
124
- - 阻塞项修复:{数量}/{总数}
125
- - 主要问题修复:{数量}/{总数}
126
- - 次要问题修复:{数量}/{总数}
127
- - 所有测试通过:{是/否}
128
- - 审查输入:{review-artifact}
129
- - 修复产物:{refinement-artifact}
130
-
131
- 下一步 - 重新审查或提交:
132
- - 重新审查(默认推荐;修复了 Blocker/Major 时优先):
133
- - Claude Code / OpenCode:/review-task {task-id}
134
- - Gemini CLI:/agent-infra:review-task {task-id}
135
- - Codex CLI:$review-task {task-id}
136
- - 直接提交(仅限只修复 Minor 且风险可控):
137
- - Claude Code / OpenCode:/commit
138
- - Gemini CLI:/agent-infra:commit
139
- - Codex CLI:$commit
140
- ```
57
+ 更新 task.md,并追加:
58
+ `- {yyyy-MM-dd HH:mm:ss} — **Refinement (Round {N}, for {review-artifact})** by {agent} — Fixed {n} blockers, {n} major, {n} minor issues → {refinement-artifact}`
141
59
 
142
- ## 输出模板
60
+ ### 7. 告知用户
143
61
 
144
- ```markdown
145
- # 修复报告
146
-
147
- - **修复轮次**:Round {refinement-round}
148
- - **产物文件**:`{refinement-artifact}`
149
- - **审查输入**:`{review-artifact}`
150
- - **实现上下文**:`{implementation-artifact}`
151
-
152
- ### 审查反馈处理
153
-
154
- #### 阻塞项修复
155
- 1. **{问题标题}**(来自 {review-artifact})
156
- - **修复**:{做了什么修改}
157
- - **文件**:`{file-path}:{line-number}`
158
- - **验证**:{如何验证}
159
-
160
- #### 主要问题修复
161
- 1. **{问题标题}**(来自 {review-artifact})
162
- - **修复**:{做了什么修改}
163
- - **文件**:`{file-path}:{line-number}`
164
-
165
- #### 次要问题处理
166
- 1. **{问题标题}**(来自 {review-artifact})
167
- - **修复**:{做了什么修改}
168
-
169
- #### 未处理的问题
170
- - {问题}:{未处理的原因,例如不同意审查建议}
171
-
172
- ### 修复后的测试结果
173
- - 所有测试通过:{是/否}
174
- - 测试输出:{摘要}
175
- ```
62
+ 如果本轮修复了 Blocker 或 Major,默认推荐重新审查。只有在风险确实很低且只修复 Minor 时,才可把直接提交作为备选项。
176
63
 
177
64
  ## 完成检查清单
178
65
 
179
- - [ ] 阅读并理解了所有审查发现
180
- - [ ] 修复了所有阻塞项
181
- - [ ] 修复了所有主要问题
182
- - [ ] 在适当情况下处理了次要问题
183
- - [ ] 修复后所有测试通过
184
- - [ ] 创建了 `{refinement-artifact}` 修复报告
185
- - [ ] 更新了 task.md 中的任务状态
186
- - [ ] 追加了 Activity Log 条目到 task.md
187
- - [ ] 告知了用户下一步(必须展示所有 TUI 的命令格式,不要筛选)
66
+ - [ ] 已读取最新审查与实现上下文
67
+ - [ ] 已修复所有必需的 Blocker 和 Major 问题
68
+ - [ ] 已写出 `{refinement-artifact}`
69
+ - [ ] 已更新 task.md 并追加 Activity Log
70
+ - [ ] 已根据剩余风险推荐正确的下一步
188
71
 
189
72
  ## 注意事项
190
73
 
191
- 1. **前置条件**:必须有审查报告(`review.md` `review-r{N}.md` 存在)
192
- 2. **禁止自动提交**:不要自动执行 `git commit`。提醒用户手动提交
193
- 3. **范围纪律**:仅修复审查中标记的问题 —— 不添加额外变更
194
- 4. **不同意见**:如果不同意某个审查意见,在"未处理的问题"部分记录你的理由
195
- 5. **重新审查**:修复阻塞项后,建议重新运行 review-task 技能进行验证
196
- 6. **一致性要求**:最新审查产物、Activity Log 记录和修复报告标题必须引用同一轮次文件
197
- 7. **版本化规则**:首轮修复使用 `refinement.md`;后续轮次使用 `refinement-r{N}.md`
74
+ - 首轮修复使用 `refinement.md`,后续轮次使用 `refinement-r{N}.md`
75
+ - 若不同意审查意见,要在报告的未解决问题中记录理由
76
+ - 不要把范围扩展到审查项之外
198
77
 
199
78
  ## 停止
200
79
 
201
- 完成检查清单后,**立即停止**。等待用户审查修复结果并决定重新审查还是提交。
80
+ 完成检查清单后立即停止。
202
81
 
203
82
  ## 错误处理
204
83
 
205
- - 任务未找到:提示 "Task {task-id} not found"
206
- - 缺少审查报告:提示 "Review report not found, please run the review-task skill first"
207
- - 审查产物不一致:提示 "Review artifact mismatch: Activity Log references {expected} but file not found. Please verify the review artifact exists."
208
- - 修复后测试失败:输出测试错误,询问用户如何处理
84
+ - 任务未找到:`Task {task-id} not found`
85
+ - 缺少审查报告:`Review report not found, please run the review-task skill first`
86
+ - 审查产物不一致:`Review artifact mismatch: Activity Log references {expected} but file not found. Please verify the review artifact exists.`
@@ -0,0 +1,76 @@
1
+ # Fix Workflow
2
+
3
+ Read this file before changing code during refinement.
4
+
5
+ ## Plan the Fixes
6
+
7
+ Classify and prioritize work:
8
+ 1. **Blockers first**
9
+ 2. **Then major issues**
10
+ 3. **Finally minor issues**
11
+
12
+ For each finding, determine:
13
+ - which files must change
14
+ - what specific fix is required
15
+ - how the fix will be verified
16
+
17
+ Detailed priority rules:
18
+ - Blockers must all be fixed before anything else
19
+ - Major issues should all be fixed in the same pass unless a blocker prevents progress
20
+ - Minor issues are optional only after Blockers and Majors are resolved
21
+ - If you disagree with a finding, record that disagreement under unresolved issues instead of silently skipping it
22
+
23
+ ## Execute the Fixes
24
+
25
+ For each fix:
26
+ 1. read the affected files
27
+ 2. apply the smallest necessary change
28
+ 3. verify the change addresses the review feedback
29
+ 4. run the relevant tests
30
+
31
+ ## Run Test Verification
32
+
33
+ Run the project test command from the `test` skill and confirm that all required tests still pass.
34
+
35
+ ## Choose the Next-Step Branch
36
+
37
+ Decision rules:
38
+ 1. if this round fixed any `Blocker` or `Major`, recommend re-review by default
39
+ 2. only when this round fixed Minor issues only and the change is clearly low risk may direct commit be offered as an option
40
+ 3. if any `Blocker` or `Major` remains unresolved, do not suggest direct commit
41
+
42
+ Prohibition:
43
+ - never present direct commit as the only next step unless no high-risk issue remains
44
+
45
+ Required output template:
46
+
47
+ ```text
48
+ Task {task-id} refinement completed.
49
+
50
+ Refinement status:
51
+ - Blockers fixed: {fixed-blockers}/{total-blockers}
52
+ - Major issues fixed: {fixed-majors}/{total-majors}
53
+ - Minor issues fixed: {fixed-minors}/{total-minors}
54
+ - All tests passing: {yes/no}
55
+ - Review input: {review-artifact}
56
+ - Refinement artifact: {refinement-artifact}
57
+
58
+ Next step - re-review or commit:
59
+ - Re-review (recommended by default when Blocker/Major issues were fixed):
60
+ - Claude Code / OpenCode: /review-task {task-id}
61
+ - Gemini CLI: /agent-infra:review-task {task-id}
62
+ - Codex CLI: $review-task {task-id}
63
+ - Commit directly (Minor-only, low-risk changes only):
64
+ - Claude Code / OpenCode: /commit
65
+ - Gemini CLI: /agent-infra:commit
66
+ - Codex CLI: $commit
67
+ ```
68
+
69
+ ## Notes
70
+
71
+ 1. **Prerequisite**: a review artifact must exist (`review.md` or `review-r{N}.md`)
72
+ 2. **No auto-commit**: do not run `git commit`
73
+ 3. **Scope discipline**: only fix reviewed issues
74
+ 4. **Disagreement handling**: record any disagreement in the report
75
+ 5. **Re-review**: after fixing Blockers or Major issues, recommend `review-task`
76
+ 6. **Consistency**: the latest review artifact, Activity Log entry, and refinement report must reference the same round
@@ -0,0 +1,76 @@
1
+ # 修复工作流
2
+
3
+ 在修复阶段修改代码之前先读取本文件。
4
+
5
+ ## 规划修复
6
+
7
+ 按以下顺序分类并确定优先级:
8
+ 1. **先处理 Blocker**
9
+ 2. **再处理 Major**
10
+ 3. **最后处理 Minor**
11
+
12
+ 对每一个问题,都要明确:
13
+ - 哪些文件必须修改
14
+ - 具体需要怎样修复
15
+ - 如何验证修复已经生效
16
+
17
+ 详细优先级规则:
18
+ - 所有 Blocker 都必须最先修完
19
+ - 只要没有被 Blocker 阻塞,所有 Major 都应在同一轮一并修复
20
+ - 只有在 Blocker 和 Major 都解决后,Minor 才是可选项
21
+ - 如果你不同意某条审查意见,不要静默跳过,而是把分歧记录到 unresolved issues
22
+
23
+ ## 执行修复
24
+
25
+ 对每一项修复:
26
+ 1. 读取受影响文件
27
+ 2. 施加最小必要改动
28
+ 3. 验证改动确实解决了审查反馈
29
+ 4. 运行相关测试
30
+
31
+ ## 运行测试验证
32
+
33
+ 运行项目测试命令。项目测试命令以 `test` skill 为准,并确认所有必需测试仍然通过。
34
+
35
+ ## 选择下一步分支
36
+
37
+ 判断规则:
38
+ 1. 如果本轮修复了任何 `Blocker` 或 `Major`,默认推荐重新审查
39
+ 2. 只有当本轮只修复了 Minor,且改动明显低风险时,才可以把直接提交作为一个可选项
40
+ 3. 如果仍有任何 `Blocker` 或 `Major` 未解决,就不要建议直接提交
41
+
42
+ 禁止规则:
43
+ - 只要还存在高风险问题,绝对不要把直接提交写成唯一下一步
44
+
45
+ 必用输出模板:
46
+
47
+ ```text
48
+ 任务 {task-id} 修复完成。
49
+
50
+ 修复情况:
51
+ - 阻塞项修复:{数量}/{总数}
52
+ - 主要问题修复:{数量}/{总数}
53
+ - 次要问题修复:{数量}/{总数}
54
+ - 所有测试通过:{是/否}
55
+ - 审查输入:{review-artifact}
56
+ - 修复产物:{refinement-artifact}
57
+
58
+ 下一步 - 重新审查或提交:
59
+ - 重新审查(默认推荐;修复了 Blocker/Major 时优先):
60
+ - Claude Code / OpenCode:/review-task {task-id}
61
+ - Gemini CLI:/agent-infra:review-task {task-id}
62
+ - Codex CLI:$review-task {task-id}
63
+ - 直接提交(仅限只修复 Minor 且风险可控):
64
+ - Claude Code / OpenCode:/commit
65
+ - Gemini CLI:/agent-infra:commit
66
+ - Codex CLI:$commit
67
+ ```
68
+
69
+ ## 注意事项
70
+
71
+ 1. **前置条件**:必须存在审查产物(`review.md` 或 `review-r{N}.md`)
72
+ 2. **禁止自动提交**:不要执行 `git commit`
73
+ 3. **范围约束**:只修复审查中列出的问题
74
+ 4. **分歧处理**:如果不同意审查意见,要在报告里明确记录
75
+ 5. **重新审查**:修复了 Blocker 或 Major 后,推荐执行 `review-task`
76
+ 6. **一致性**:最新审查产物、Activity Log 记录和修复报告必须引用同一轮次
@@ -0,0 +1,38 @@
1
+ # Refinement Report Template
2
+
3
+ Use this structure when writing `refinement.md` or `refinement-r{N}.md`.
4
+
5
+ ## Output Template
6
+
7
+ ```markdown
8
+ # Refinement Report
9
+
10
+ - **Refinement Round**: Round {refinement-round}
11
+ - **Artifact File**: `{refinement-artifact}`
12
+ - **Review Input**: `{review-artifact}`
13
+ - **Implementation Context**: `{implementation-artifact}`
14
+
15
+ ### Review Feedback Handling
16
+
17
+ #### Blocker Fixes
18
+ 1. **{issue-title}**
19
+ - **Fix**: {what changed}
20
+ - **File**: `{file-path}:{line-number}`
21
+ - **Validation**: {validation}
22
+
23
+ #### Major Issue Fixes
24
+ 1. **{issue-title}**
25
+ - **Fix**: {what changed}
26
+ - **File**: `{file-path}:{line-number}`
27
+
28
+ #### Minor Issue Handling
29
+ 1. **{issue-title}**
30
+ - **Fix**: {what changed}
31
+
32
+ #### Unresolved Issues
33
+ - {issue}: {reason}
34
+
35
+ ### Test Results After Refinement
36
+ - All tests passing: {yes/no}
37
+ - Test output: {summary}
38
+ ```
@@ -0,0 +1,38 @@
1
+ # 修复报告模板
2
+
3
+ 编写 `refinement.md` 或 `refinement-r{N}.md` 时,使用以下结构。
4
+
5
+ ## 输出模板
6
+
7
+ ```markdown
8
+ # 修复报告
9
+
10
+ - **修复轮次**: Round {refinement-round}
11
+ - **产物文件**: `{refinement-artifact}`
12
+ - **审查输入**: `{review-artifact}`
13
+ - **实现上下文**: `{implementation-artifact}`
14
+
15
+ ### 审查反馈处理
16
+
17
+ #### 阻塞项修复
18
+ 1. **{issue-title}**
19
+ - **修复**: {what changed}
20
+ - **文件**: `{file-path}:{line-number}`
21
+ - **验证**: {validation}
22
+
23
+ #### 主要问题修复
24
+ 1. **{issue-title}**
25
+ - **修复**: {what changed}
26
+ - **文件**: `{file-path}:{line-number}`
27
+
28
+ #### 次要问题处理
29
+ 1. **{issue-title}**
30
+ - **修复**: {what changed}
31
+
32
+ #### 未解决问题
33
+ - {issue}: {reason}
34
+
35
+ ### 修复后的测试结果
36
+ - 所有测试通过: {yes/no}
37
+ - 测试输出: {summary}
38
+ ```
@@ -1,9 +1,6 @@
1
1
  ---
2
2
  name: refine-title
3
- description: >
4
- Deeply analyze Issue or PR content and reformat the title to
5
- Conventional Commits format. Triggered when the user requests
6
- title optimization. Argument: issue or PR number.
3
+ description: "Rewrite an Issue or PR title in Conventional Commits format"
7
4
  ---
8
5
 
9
6
  # Refine Title
@@ -1,8 +1,6 @@
1
1
  ---
2
2
  name: refine-title
3
- description: >
4
- 深度分析 Issue 或 PR 内容,并将其标题重构为 Conventional Commits 格式。
5
- 当用户要求优化标题时触发。参数:issue 或 PR 编号。
3
+ description: "重构 Issue/PR 标题为 Conventional Commits 格式"
6
4
  ---
7
5
 
8
6
  # 重构标题
@@ -1,8 +1,6 @@
1
1
  ---
2
2
  name: release
3
- description: >
4
- Execute the version release workflow. Triggered when the user
5
- requests a version release. Argument: version number (X.Y.Z).
3
+ description: "Run the version release workflow"
6
4
  ---
7
5
 
8
6
  # Version Release
@@ -13,7 +11,7 @@ Execute the version release workflow for the specified version.
13
11
 
14
12
  ## Execution Flow
15
13
 
16
- ### Step 1: Parse and Validate Version
14
+ ### 1. Parse and Validate Version
17
15
 
18
16
  Extract version from arguments. Must match `X.Y.Z` format.
19
17
 
@@ -23,7 +21,7 @@ Parse components:
23
21
 
24
22
  If format is invalid, error: "Version format incorrect, expected X.Y.Z (e.g. 1.2.3)"
25
23
 
26
- ### Step 2: Verify Clean Workspace
24
+ ### 2. Verify Clean Workspace
27
25
 
28
26
  ```bash
29
27
  git status --short
@@ -31,7 +29,26 @@ git status --short
31
29
 
32
30
  If there are uncommitted changes, error: "Workspace has uncommitted changes. Please commit or stash first."
33
31
 
34
- ### Step 3: Update Version References
32
+ ### 3. Pre-release Verification
33
+
34
+ <!-- TODO: Replace with your project's pre-release verification steps -->
35
+
36
+ Run any checks that must pass before preparing a release:
37
+
38
+ ```bash
39
+ git branch --show-current
40
+ # TODO: Replace with your project's test/build verification commands
41
+ ```
42
+
43
+ Verification guidance:
44
+ - Confirm the release is being prepared from the correct branch for your project
45
+ - Run the full validation commands required by your release process
46
+
47
+ Handling rules:
48
+ - If the current branch is unexpected, print a warning or exit based on your policy
49
+ - If any verification command fails, stop the release process and fix the issue first
50
+
51
+ ### 4. Update Version References
35
52
 
36
53
  <!-- TODO: Replace with your project's version update steps -->
37
54
 
@@ -45,6 +62,7 @@ Search for version references in project files and update them:
45
62
 
46
63
  **Common files to update**:
47
64
  - `package.json` (Node.js)
65
+ - `package-lock.json` (Node.js; run `npm install --package-lock-only` after updating `package.json`)
48
66
  - `pom.xml` (Maven)
49
67
  - `setup.py` / `pyproject.toml` (Python)
50
68
  - `version.go` (Go)
@@ -52,22 +70,39 @@ Search for version references in project files and update them:
52
70
  - `SECURITY.md` / `SECURITY.zh-CN.md` (supported version table)
53
71
 
54
72
  **Exclude from version replacement**:
55
- - `.agents/`, `.agent-workspace/`, `.claude/`, `.codex/`, `.gemini/`, `.opencode/` (AI tool configs)
73
+ - `.agents/`, `.agents/workspace/`, `.claude/`, `.codex/`, `.gemini/`, `.opencode/` (AI tool configs)
74
+
75
+ If the project uses `package-lock.json`, run `npm install --package-lock-only` after updating `package.json` so the lockfile version stays in sync.
76
+
77
+ ### 5. Rebuild Artifacts
56
78
 
57
- ### Step 4: Create Release Commit
79
+ <!-- TODO: Replace with your project's artifact rebuild steps -->
80
+
81
+ If version updates affect generated files, embedded metadata, or bundled assets, rebuild them now:
82
+
83
+ ```bash
84
+ # TODO: Replace with your project's rebuild command(s)
85
+ ```
86
+
87
+ Execution guidance:
88
+ - Run this after updating version references so generated artifacts pick up the new version
89
+ - If your project has no generated artifacts, document that explicitly in the project-specific skill
90
+ - If the rebuild fails, stop the release process and fix the build first
91
+
92
+ ### 6. Create Release Commit
58
93
 
59
94
  ```bash
60
95
  git add -A
61
96
  git commit -m "chore: release v{version}"
62
97
  ```
63
98
 
64
- ### Step 5: Create Git Tag
99
+ ### 7. Create Git Tag
65
100
 
66
101
  ```bash
67
102
  git tag v{version}
68
103
  ```
69
104
 
70
- ### Step 6: Manage Milestones
105
+ ### 8. Manage Milestones
71
106
 
72
107
  Close the milestone for the released version when it exists, and create the missing planning milestones for the next cycle.
73
108
 
@@ -84,7 +119,7 @@ The script is responsible for:
84
119
  - When `PATCH=0`, also ensuring `{MAJOR}.{MINOR+1}.0` and `{MAJOR}.{MINOR+1}.x`
85
120
  - Printing a milestone summary with the released milestone action and new milestone count
86
121
 
87
- ### Step 7: Output Summary
122
+ ### 9. Output Summary
88
123
 
89
124
  > **IMPORTANT**: All TUI command formats listed below must be output in full. Do not show only the format for the current AI agent.
90
125
 
@@ -100,12 +135,12 @@ Files updated: {count}
100
135
 
101
136
  Next steps (manual):
102
137
 
103
- 1. Push tag:
104
- git push origin v{version}
105
-
106
- 2. Push branch:
138
+ 1. Push branch:
107
139
  git push origin {current-branch}
108
140
 
141
+ 2. Push tag:
142
+ git push origin v{version}
143
+
109
144
  3. (Optional) Generate release notes:
110
145
  - Claude Code / OpenCode: /create-release-note {version}
111
146
  - Gemini CLI: /{{project}}:create-release-note {version}
@@ -130,13 +165,17 @@ git checkout -- .
130
165
 
131
166
  1. **Clean workspace required**: Must have no uncommitted changes
132
167
  2. **No auto-push**: All operations are local only; user pushes manually
133
- 3. **No build verification**: Run the test skill before releasing to verify
134
- 4. **Version replacement scope**: Search determines which files to update; exclude AI tool directories
135
- 5. **Adapt to your project**: The version update steps above are generic; customize for your project's versioning scheme
136
- 6. **Milestone coordination**: Releases should create the next planning milestones automatically; initialize the taxonomy first with `init-milestones` when needed
168
+ 3. **Pre-release verification**: Replace the Step 3 TODOs with the branch, test, and validation commands your release process requires
169
+ 4. **Generated artifacts**: Replace the Step 5 TODOs when version changes affect generated files, bundled assets, or embedded metadata
170
+ 5. **Release automation**: If pushing a tag triggers CI/CD or package publishing, confirm the required credentials and pipeline settings first
171
+ 6. **Version replacement scope**: Search determines which files to update; exclude AI tool directories
172
+ 7. **Adapt to your project**: The version update and rebuild steps above are generic; customize them for your project's versioning scheme
173
+ 8. **Milestone coordination**: Releases should create the next planning milestones automatically; initialize the taxonomy first with `init-milestones` when needed
137
174
 
138
175
  ## Error Handling
139
176
 
140
177
  - Invalid version format: Prompt correct format and exit
141
178
  - Dirty workspace: Prompt to commit or stash
179
+ - Verification failure: Display the failing check and stop the release
180
+ - Artifact rebuild failure: Display the build error and stop the release
142
181
  - Git operation failure: Display error and provide rollback instructions