@waoooo/claude-skills 1.0.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.
Files changed (264) hide show
  1. package/README.md +48 -0
  2. package/package.json +28 -0
  3. package/registry.json +431 -0
  4. package/skills/acceptance-review/SKILL.md +537 -0
  5. package/skills/all-plan/SKILL.md +19 -0
  6. package/skills/all-plan/references/flow.md +750 -0
  7. package/skills/api-docs-generate/SKILL.md +204 -0
  8. package/skills/api-docs-generate/assets/templates/api.mdx +140 -0
  9. package/skills/api-docs-generate/scripts/generate-api-docs.ts +308 -0
  10. package/skills/ask/SKILL.md +42 -0
  11. package/skills/autonew/SKILL.md +34 -0
  12. package/skills/capability-analyze/SKILL.md +300 -0
  13. package/skills/capability-analyze/scripts/analyze-capabilities.ts +531 -0
  14. package/skills/capability-docs-generate/SKILL.md +155 -0
  15. package/skills/capability-docs-generate/assets/templates/capability.mdx +271 -0
  16. package/skills/capability-docs-generate/scripts/generate-capability-docs.ts +358 -0
  17. package/skills/capability-tree-query/SKILL.md +112 -0
  18. package/skills/capability-tree-query/scripts/build-capability-tree.ts +402 -0
  19. package/skills/changelog-generator/SKILL.md +104 -0
  20. package/skills/continue/SKILL.md +39 -0
  21. package/skills/continue/agents/openai.yaml +3 -0
  22. package/skills/creating-skills/SKILL.md +158 -0
  23. package/skills/creating-skills/references/official_best_practices.md +128 -0
  24. package/skills/creating-skills/references/skill_examples.md +199 -0
  25. package/skills/docx/LICENSE.txt +30 -0
  26. package/skills/docx/SKILL.md +197 -0
  27. package/skills/docx/docx-js.md +350 -0
  28. package/skills/docx/ooxml/schemas/ISO-IEC29500-4_2016/dml-chart.xsd +1499 -0
  29. package/skills/docx/ooxml/schemas/ISO-IEC29500-4_2016/dml-chartDrawing.xsd +146 -0
  30. package/skills/docx/ooxml/schemas/ISO-IEC29500-4_2016/dml-diagram.xsd +1085 -0
  31. package/skills/docx/ooxml/schemas/ISO-IEC29500-4_2016/dml-lockedCanvas.xsd +11 -0
  32. package/skills/docx/ooxml/schemas/ISO-IEC29500-4_2016/dml-main.xsd +3081 -0
  33. package/skills/docx/ooxml/schemas/ISO-IEC29500-4_2016/dml-picture.xsd +23 -0
  34. package/skills/docx/ooxml/schemas/ISO-IEC29500-4_2016/dml-spreadsheetDrawing.xsd +185 -0
  35. package/skills/docx/ooxml/schemas/ISO-IEC29500-4_2016/dml-wordprocessingDrawing.xsd +287 -0
  36. package/skills/docx/ooxml/schemas/ISO-IEC29500-4_2016/pml.xsd +1676 -0
  37. package/skills/docx/ooxml/schemas/ISO-IEC29500-4_2016/shared-additionalCharacteristics.xsd +28 -0
  38. package/skills/docx/ooxml/schemas/ISO-IEC29500-4_2016/shared-bibliography.xsd +144 -0
  39. package/skills/docx/ooxml/schemas/ISO-IEC29500-4_2016/shared-commonSimpleTypes.xsd +174 -0
  40. package/skills/docx/ooxml/schemas/ISO-IEC29500-4_2016/shared-customXmlDataProperties.xsd +25 -0
  41. package/skills/docx/ooxml/schemas/ISO-IEC29500-4_2016/shared-customXmlSchemaProperties.xsd +18 -0
  42. package/skills/docx/ooxml/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesCustom.xsd +59 -0
  43. package/skills/docx/ooxml/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesExtended.xsd +56 -0
  44. package/skills/docx/ooxml/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesVariantTypes.xsd +195 -0
  45. package/skills/docx/ooxml/schemas/ISO-IEC29500-4_2016/shared-math.xsd +582 -0
  46. package/skills/docx/ooxml/schemas/ISO-IEC29500-4_2016/shared-relationshipReference.xsd +25 -0
  47. package/skills/docx/ooxml/schemas/ISO-IEC29500-4_2016/sml.xsd +4439 -0
  48. package/skills/docx/ooxml/schemas/ISO-IEC29500-4_2016/vml-main.xsd +570 -0
  49. package/skills/docx/ooxml/schemas/ISO-IEC29500-4_2016/vml-officeDrawing.xsd +509 -0
  50. package/skills/docx/ooxml/schemas/ISO-IEC29500-4_2016/vml-presentationDrawing.xsd +12 -0
  51. package/skills/docx/ooxml/schemas/ISO-IEC29500-4_2016/vml-spreadsheetDrawing.xsd +108 -0
  52. package/skills/docx/ooxml/schemas/ISO-IEC29500-4_2016/vml-wordprocessingDrawing.xsd +96 -0
  53. package/skills/docx/ooxml/schemas/ISO-IEC29500-4_2016/wml.xsd +3646 -0
  54. package/skills/docx/ooxml/schemas/ISO-IEC29500-4_2016/xml.xsd +116 -0
  55. package/skills/docx/ooxml/schemas/ecma/fouth-edition/opc-contentTypes.xsd +42 -0
  56. package/skills/docx/ooxml/schemas/ecma/fouth-edition/opc-coreProperties.xsd +50 -0
  57. package/skills/docx/ooxml/schemas/ecma/fouth-edition/opc-digSig.xsd +49 -0
  58. package/skills/docx/ooxml/schemas/ecma/fouth-edition/opc-relationships.xsd +33 -0
  59. package/skills/docx/ooxml/schemas/mce/mc.xsd +75 -0
  60. package/skills/docx/ooxml/schemas/microsoft/wml-2010.xsd +560 -0
  61. package/skills/docx/ooxml/schemas/microsoft/wml-2012.xsd +67 -0
  62. package/skills/docx/ooxml/schemas/microsoft/wml-2018.xsd +14 -0
  63. package/skills/docx/ooxml/schemas/microsoft/wml-cex-2018.xsd +20 -0
  64. package/skills/docx/ooxml/schemas/microsoft/wml-cid-2016.xsd +13 -0
  65. package/skills/docx/ooxml/schemas/microsoft/wml-sdtdatahash-2020.xsd +4 -0
  66. package/skills/docx/ooxml/schemas/microsoft/wml-symex-2015.xsd +8 -0
  67. package/skills/docx/ooxml/scripts/pack.py +159 -0
  68. package/skills/docx/ooxml/scripts/unpack.py +29 -0
  69. package/skills/docx/ooxml/scripts/validate.py +69 -0
  70. package/skills/docx/ooxml/scripts/validation/__init__.py +15 -0
  71. package/skills/docx/ooxml/scripts/validation/base.py +951 -0
  72. package/skills/docx/ooxml/scripts/validation/docx.py +274 -0
  73. package/skills/docx/ooxml/scripts/validation/pptx.py +315 -0
  74. package/skills/docx/ooxml/scripts/validation/redlining.py +279 -0
  75. package/skills/docx/ooxml.md +610 -0
  76. package/skills/docx/scripts/__init__.py +1 -0
  77. package/skills/docx/scripts/document.py +1276 -0
  78. package/skills/docx/scripts/templates/comments.xml +3 -0
  79. package/skills/docx/scripts/templates/commentsExtended.xml +3 -0
  80. package/skills/docx/scripts/templates/commentsExtensible.xml +3 -0
  81. package/skills/docx/scripts/templates/commentsIds.xml +3 -0
  82. package/skills/docx/scripts/templates/people.xml +3 -0
  83. package/skills/docx/scripts/utilities.py +374 -0
  84. package/skills/git-branch-create/SKILL.md +170 -0
  85. package/skills/git-branch-merge/SKILL.md +176 -0
  86. package/skills/git-commit/SKILL.md +56 -0
  87. package/skills/git-commit/references/commit_examples.md +311 -0
  88. package/skills/github-actions-trigger/SKILL.md +367 -0
  89. package/skills/github-issue-create/SKILL.md +294 -0
  90. package/skills/github-pr-creation/SKILL.md +137 -0
  91. package/skills/github-pr-creation/references/pr_templates.md +187 -0
  92. package/skills/github-pr-merge/SKILL.md +112 -0
  93. package/skills/github-pr-review/SKILL.md +110 -0
  94. package/skills/github-pr-review/references/severity_guide.md +168 -0
  95. package/skills/job-create/SKILL.md +294 -0
  96. package/skills/job-create/scripts/create-job.ts +105 -0
  97. package/skills/job-workflow/SKILL.md +212 -0
  98. package/skills/keyword-extract/SKILL.md +229 -0
  99. package/skills/mcp-builder/LICENSE.txt +202 -0
  100. package/skills/mcp-builder/SKILL.md +236 -0
  101. package/skills/mcp-builder/reference/evaluation.md +602 -0
  102. package/skills/mcp-builder/reference/mcp_best_practices.md +249 -0
  103. package/skills/mcp-builder/reference/node_mcp_server.md +970 -0
  104. package/skills/mcp-builder/reference/python_mcp_server.md +719 -0
  105. package/skills/mcp-builder/scripts/connections.py +151 -0
  106. package/skills/mcp-builder/scripts/evaluation.py +373 -0
  107. package/skills/mcp-builder/scripts/example_evaluation.xml +22 -0
  108. package/skills/mcp-builder/scripts/requirements.txt +2 -0
  109. package/skills/mdx-to-openspec/SKILL.md +827 -0
  110. package/skills/mdx-to-openspec/scripts/mdx-to-openspec.ts +320 -0
  111. package/skills/mounted/SKILL.md +20 -0
  112. package/skills/multi-model-review/SKILL.md +459 -0
  113. package/skills/notion-automation/SKILL.md +215 -0
  114. package/skills/openspec-review/SKILL.md +513 -0
  115. package/skills/pdf/LICENSE.txt +30 -0
  116. package/skills/pdf/SKILL.md +294 -0
  117. package/skills/pdf/forms.md +205 -0
  118. package/skills/pdf/reference.md +612 -0
  119. package/skills/pdf/scripts/check_bounding_boxes.py +70 -0
  120. package/skills/pdf/scripts/check_bounding_boxes_test.py +226 -0
  121. package/skills/pdf/scripts/check_fillable_fields.py +12 -0
  122. package/skills/pdf/scripts/convert_pdf_to_images.py +35 -0
  123. package/skills/pdf/scripts/create_validation_image.py +41 -0
  124. package/skills/pdf/scripts/extract_form_field_info.py +152 -0
  125. package/skills/pdf/scripts/fill_fillable_fields.py +114 -0
  126. package/skills/pdf/scripts/fill_pdf_form_with_annotations.py +108 -0
  127. package/skills/pend/SKILL.md +33 -0
  128. package/skills/ping/SKILL.md +39 -0
  129. package/skills/pptx/LICENSE.txt +30 -0
  130. package/skills/pptx/SKILL.md +484 -0
  131. package/skills/pptx/html2pptx.md +625 -0
  132. package/skills/pptx/ooxml/schemas/ISO-IEC29500-4_2016/dml-chart.xsd +1499 -0
  133. package/skills/pptx/ooxml/schemas/ISO-IEC29500-4_2016/dml-chartDrawing.xsd +146 -0
  134. package/skills/pptx/ooxml/schemas/ISO-IEC29500-4_2016/dml-diagram.xsd +1085 -0
  135. package/skills/pptx/ooxml/schemas/ISO-IEC29500-4_2016/dml-lockedCanvas.xsd +11 -0
  136. package/skills/pptx/ooxml/schemas/ISO-IEC29500-4_2016/dml-main.xsd +3081 -0
  137. package/skills/pptx/ooxml/schemas/ISO-IEC29500-4_2016/dml-picture.xsd +23 -0
  138. package/skills/pptx/ooxml/schemas/ISO-IEC29500-4_2016/dml-spreadsheetDrawing.xsd +185 -0
  139. package/skills/pptx/ooxml/schemas/ISO-IEC29500-4_2016/dml-wordprocessingDrawing.xsd +287 -0
  140. package/skills/pptx/ooxml/schemas/ISO-IEC29500-4_2016/pml.xsd +1676 -0
  141. package/skills/pptx/ooxml/schemas/ISO-IEC29500-4_2016/shared-additionalCharacteristics.xsd +28 -0
  142. package/skills/pptx/ooxml/schemas/ISO-IEC29500-4_2016/shared-bibliography.xsd +144 -0
  143. package/skills/pptx/ooxml/schemas/ISO-IEC29500-4_2016/shared-commonSimpleTypes.xsd +174 -0
  144. package/skills/pptx/ooxml/schemas/ISO-IEC29500-4_2016/shared-customXmlDataProperties.xsd +25 -0
  145. package/skills/pptx/ooxml/schemas/ISO-IEC29500-4_2016/shared-customXmlSchemaProperties.xsd +18 -0
  146. package/skills/pptx/ooxml/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesCustom.xsd +59 -0
  147. package/skills/pptx/ooxml/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesExtended.xsd +56 -0
  148. package/skills/pptx/ooxml/schemas/ISO-IEC29500-4_2016/shared-documentPropertiesVariantTypes.xsd +195 -0
  149. package/skills/pptx/ooxml/schemas/ISO-IEC29500-4_2016/shared-math.xsd +582 -0
  150. package/skills/pptx/ooxml/schemas/ISO-IEC29500-4_2016/shared-relationshipReference.xsd +25 -0
  151. package/skills/pptx/ooxml/schemas/ISO-IEC29500-4_2016/sml.xsd +4439 -0
  152. package/skills/pptx/ooxml/schemas/ISO-IEC29500-4_2016/vml-main.xsd +570 -0
  153. package/skills/pptx/ooxml/schemas/ISO-IEC29500-4_2016/vml-officeDrawing.xsd +509 -0
  154. package/skills/pptx/ooxml/schemas/ISO-IEC29500-4_2016/vml-presentationDrawing.xsd +12 -0
  155. package/skills/pptx/ooxml/schemas/ISO-IEC29500-4_2016/vml-spreadsheetDrawing.xsd +108 -0
  156. package/skills/pptx/ooxml/schemas/ISO-IEC29500-4_2016/vml-wordprocessingDrawing.xsd +96 -0
  157. package/skills/pptx/ooxml/schemas/ISO-IEC29500-4_2016/wml.xsd +3646 -0
  158. package/skills/pptx/ooxml/schemas/ISO-IEC29500-4_2016/xml.xsd +116 -0
  159. package/skills/pptx/ooxml/schemas/ecma/fouth-edition/opc-contentTypes.xsd +42 -0
  160. package/skills/pptx/ooxml/schemas/ecma/fouth-edition/opc-coreProperties.xsd +50 -0
  161. package/skills/pptx/ooxml/schemas/ecma/fouth-edition/opc-digSig.xsd +49 -0
  162. package/skills/pptx/ooxml/schemas/ecma/fouth-edition/opc-relationships.xsd +33 -0
  163. package/skills/pptx/ooxml/schemas/mce/mc.xsd +75 -0
  164. package/skills/pptx/ooxml/schemas/microsoft/wml-2010.xsd +560 -0
  165. package/skills/pptx/ooxml/schemas/microsoft/wml-2012.xsd +67 -0
  166. package/skills/pptx/ooxml/schemas/microsoft/wml-2018.xsd +14 -0
  167. package/skills/pptx/ooxml/schemas/microsoft/wml-cex-2018.xsd +20 -0
  168. package/skills/pptx/ooxml/schemas/microsoft/wml-cid-2016.xsd +13 -0
  169. package/skills/pptx/ooxml/schemas/microsoft/wml-sdtdatahash-2020.xsd +4 -0
  170. package/skills/pptx/ooxml/schemas/microsoft/wml-symex-2015.xsd +8 -0
  171. package/skills/pptx/ooxml/scripts/pack.py +159 -0
  172. package/skills/pptx/ooxml/scripts/unpack.py +29 -0
  173. package/skills/pptx/ooxml/scripts/validate.py +69 -0
  174. package/skills/pptx/ooxml/scripts/validation/__init__.py +15 -0
  175. package/skills/pptx/ooxml/scripts/validation/base.py +951 -0
  176. package/skills/pptx/ooxml/scripts/validation/docx.py +274 -0
  177. package/skills/pptx/ooxml/scripts/validation/pptx.py +315 -0
  178. package/skills/pptx/ooxml/scripts/validation/redlining.py +279 -0
  179. package/skills/pptx/ooxml.md +427 -0
  180. package/skills/pptx/scripts/html2pptx.js +979 -0
  181. package/skills/pptx/scripts/inventory.py +1020 -0
  182. package/skills/pptx/scripts/rearrange.py +231 -0
  183. package/skills/pptx/scripts/replace.py +385 -0
  184. package/skills/pptx/scripts/thumbnail.py +450 -0
  185. package/skills/progress-update/SKILL.md +394 -0
  186. package/skills/progress-update/scripts/update-progress.ts +221 -0
  187. package/skills/release-automation/SKILL.md +306 -0
  188. package/skills/requirement-parse/SKILL.md +212 -0
  189. package/skills/requirement-parse/scripts/infer-builder-config.ts +346 -0
  190. package/skills/requirement-parse/scripts/merge-requirements.ts +228 -0
  191. package/skills/requirement-parse/scripts/parse-docs.ts +206 -0
  192. package/skills/requirement-parse/scripts/parse-openspec.ts +168 -0
  193. package/skills/roadmap-docs-generate/SKILL.md +483 -0
  194. package/skills/roadmap-docs-generate/assets/templates/ROADMAP.mdx +75 -0
  195. package/skills/roadmap-docs-generate/assets/templates/ROADMAP.mdx.template +330 -0
  196. package/skills/roadmap-docs-generate/assets/templates/TODO.mdx +56 -0
  197. package/skills/roadmap-docs-generate/assets/templates/TODO.mdx.template +363 -0
  198. package/skills/roadmap-docs-generate/scripts/json-to-mdx.ts +445 -0
  199. package/skills/roadmap-docs-generate/scripts/json-to-mdx.ts.backup +411 -0
  200. package/skills/roadmap-generate/SKILL.md +396 -0
  201. package/skills/roadmap-generate/scripts/generate-roadmap.ts +496 -0
  202. package/skills/skill-creator/LICENSE.txt +202 -0
  203. package/skills/skill-creator/SKILL.md +356 -0
  204. package/skills/skill-creator/references/output-patterns.md +82 -0
  205. package/skills/skill-creator/references/workflows.md +28 -0
  206. package/skills/skill-creator/scripts/init_skill.py +303 -0
  207. package/skills/skill-creator/scripts/package_skill.py +110 -0
  208. package/skills/skill-creator/scripts/quick_validate.py +95 -0
  209. package/skills/spec-generate/SKILL.md +408 -0
  210. package/skills/spec-generate/scripts/generate-specs.ts +538 -0
  211. package/skills/spec-generate/scripts/generate-tasks.ts +174 -0
  212. package/skills/specs-review/SKILL.md +370 -0
  213. package/skills/task-execute/SKILL.md +399 -0
  214. package/skills/task-update-status/SKILL.md +349 -0
  215. package/skills/task-update-status/scripts/update-task-status.ts +192 -0
  216. package/skills/task-verify/SKILL.md +407 -0
  217. package/skills/ui-ux-pro-max/SKILL.md +386 -0
  218. package/skills/ui-ux-pro-max/data/charts.csv +26 -0
  219. package/skills/ui-ux-pro-max/data/colors.csv +97 -0
  220. package/skills/ui-ux-pro-max/data/icons.csv +101 -0
  221. package/skills/ui-ux-pro-max/data/landing.csv +31 -0
  222. package/skills/ui-ux-pro-max/data/products.csv +97 -0
  223. package/skills/ui-ux-pro-max/data/react-performance.csv +45 -0
  224. package/skills/ui-ux-pro-max/data/stacks/astro.csv +54 -0
  225. package/skills/ui-ux-pro-max/data/stacks/flutter.csv +53 -0
  226. package/skills/ui-ux-pro-max/data/stacks/html-tailwind.csv +56 -0
  227. package/skills/ui-ux-pro-max/data/stacks/jetpack-compose.csv +53 -0
  228. package/skills/ui-ux-pro-max/data/stacks/nextjs.csv +53 -0
  229. package/skills/ui-ux-pro-max/data/stacks/nuxt-ui.csv +51 -0
  230. package/skills/ui-ux-pro-max/data/stacks/nuxtjs.csv +59 -0
  231. package/skills/ui-ux-pro-max/data/stacks/react-native.csv +52 -0
  232. package/skills/ui-ux-pro-max/data/stacks/react.csv +54 -0
  233. package/skills/ui-ux-pro-max/data/stacks/shadcn.csv +61 -0
  234. package/skills/ui-ux-pro-max/data/stacks/svelte.csv +54 -0
  235. package/skills/ui-ux-pro-max/data/stacks/swiftui.csv +51 -0
  236. package/skills/ui-ux-pro-max/data/stacks/vue.csv +50 -0
  237. package/skills/ui-ux-pro-max/data/styles.csv +68 -0
  238. package/skills/ui-ux-pro-max/data/typography.csv +58 -0
  239. package/skills/ui-ux-pro-max/data/ui-reasoning.csv +101 -0
  240. package/skills/ui-ux-pro-max/data/ux-guidelines.csv +100 -0
  241. package/skills/ui-ux-pro-max/data/web-interface.csv +31 -0
  242. package/skills/ui-ux-pro-max/scripts/core.py +253 -0
  243. package/skills/ui-ux-pro-max/scripts/design_system.py +1067 -0
  244. package/skills/ui-ux-pro-max/scripts/search.py +114 -0
  245. package/skills/vercel-automation/SKILL.md +226 -0
  246. package/skills/webapp-testing/LICENSE.txt +202 -0
  247. package/skills/webapp-testing/SKILL.md +96 -0
  248. package/skills/webapp-testing/examples/console_logging.py +35 -0
  249. package/skills/webapp-testing/examples/element_discovery.py +40 -0
  250. package/skills/webapp-testing/examples/static_html_automation.py +33 -0
  251. package/skills/webapp-testing/scripts/with_server.py +106 -0
  252. package/skills/worktree-manager/SKILL.md +725 -0
  253. package/skills/worktree-manager/config.json +15 -0
  254. package/skills/worktree-manager/scripts/allocate-ports.sh +100 -0
  255. package/skills/worktree-manager/scripts/cleanup.sh +185 -0
  256. package/skills/worktree-manager/scripts/launch-agent.sh +155 -0
  257. package/skills/worktree-manager/scripts/register.sh +125 -0
  258. package/skills/worktree-manager/scripts/release-ports.sh +48 -0
  259. package/skills/worktree-manager/scripts/status.sh +169 -0
  260. package/skills/worktree-manager/scripts/sync.sh +168 -0
  261. package/skills/worktree-manager/templates/worktree.json +23 -0
  262. package/skills/xlsx/LICENSE.txt +30 -0
  263. package/skills/xlsx/SKILL.md +289 -0
  264. package/skills/xlsx/recalc.py +178 -0
@@ -0,0 +1,349 @@
1
+ # Skill: task-update-status
2
+
3
+ ## 功能
4
+
5
+ ꛓꖰ OpenSpec tasks.md äø­ēš„ä»»åŠ”ēŠ¶ę€ę ‡č®°ļ¼ˆ`- [ ]` → `- [x]`)。
6
+
7
+ ## ä½•ę—¶č°ƒē”Ø
8
+
9
+ - ę­„éŖ¤ 17ļ¼šä»»åŠ”éŖŒčÆé€ščæ‡åŽ
10
+ - éœ€č¦ę ‡č®°ä»»åŠ”å®Œęˆę—¶
11
+ - 回写 OpenSpec ēŠ¶ę€ę—¶
12
+
13
+ ## 输兄
14
+
15
+ - `taskId` - 任劔 IDļ¼ˆä¾‹å¦‚ļ¼šTASK-001)
16
+ - `jobId` - Job IDļ¼ˆä¾‹å¦‚ļ¼š2026-02-10-1520-pricing-system)
17
+ - `openspecPath` - OpenSpec ē›®å½•č·Æå¾„ļ¼ˆä¾‹å¦‚ļ¼šopenspec/changes/001-pricing-system/)
18
+ - `status` - ę–°ēŠ¶ę€ļ¼ˆpending / in-progress / completed / failed)
19
+
20
+ ## 输出
21
+
22
+ - ę›“ę–°åŽēš„ tasks.md
23
+ - 曓新旄志
24
+
25
+ ## ę‰§č”Œę­„éŖ¤
26
+
27
+ ### 1. čÆ»å– tasks.md
28
+
29
+ ```typescript
30
+ const tasksPath = `${openspecPath}/tasks.md`
31
+ const content = readFile(tasksPath)
32
+ ```
33
+
34
+ ### 2. 定位任劔
35
+
36
+ ```typescript
37
+ // 从 tasks.json čŽ·å–ä»»åŠ”äæ”ęÆ
38
+ const tasks = JSON.parse(readFile(`exports/jobs/${jobId}/specs/tasks.json`))
39
+ const task = tasks.tasks.find(t => t.taskId === taskId)
40
+
41
+ if (!task) {
42
+ throw new Error(`Task ${taskId} not found`)
43
+ }
44
+
45
+ // čŽ·å–ä»»åŠ”åœØ MDX äø­ēš„å¼•ē”Øäæ”ęÆ
46
+ const mdxRef = task.mdxRef
47
+ // mdxRef: { file, line, marker }
48
+ ```
49
+
50
+ ### 3. ę›“ę–°ēŠ¶ę€ę ‡č®°
51
+
52
+ ```typescript
53
+ const lines = content.split('\n')
54
+
55
+ // 方法 1ļ¼šé€ščæ‡ marker ē²¾ē”®åŒ¹é…
56
+ if (mdxRef && mdxRef.marker) {
57
+ const targetLine = lines.findIndex(line =>
58
+ line.trim() === mdxRef.marker.trim()
59
+ )
60
+
61
+ if (targetLine !== -1) {
62
+ // ę›“ę–°ēŠ¶ę€
63
+ if (status === 'completed') {
64
+ lines[targetLine] = lines[targetLine].replace('- [ ]', '- [x]')
65
+ } else if (status === 'pending') {
66
+ lines[targetLine] = lines[targetLine].replace('- [x]', '- [ ]')
67
+ }
68
+ }
69
+ }
70
+
71
+ // 方法 2ļ¼šé€ščæ‡ä»»åŠ”ę ‡é¢˜ęØ”ē³ŠåŒ¹é…
72
+ else {
73
+ const taskTitle = task.title
74
+ const targetLine = lines.findIndex(line =>
75
+ line.includes(taskTitle) &&
76
+ (line.includes('- [ ]') || line.includes('- [x]'))
77
+ )
78
+
79
+ if (targetLine !== -1) {
80
+ if (status === 'completed') {
81
+ lines[targetLine] = lines[targetLine].replace('- [ ]', '- [x]')
82
+ } else if (status === 'pending') {
83
+ lines[targetLine] = lines[targetLine].replace('- [x]', '- [ ]')
84
+ }
85
+ }
86
+ }
87
+
88
+ const updatedContent = lines.join('\n')
89
+ ```
90
+
91
+ ### 4. 写兄文件
92
+
93
+ ```typescript
94
+ writeFile(tasksPath, updatedContent)
95
+ ```
96
+
97
+ ### 5. 记录曓新旄志
98
+
99
+ ```typescript
100
+ const log = {
101
+ taskId: taskId,
102
+ jobId: jobId,
103
+ updatedAt: new Date().toISOString(),
104
+ file: 'tasks.md',
105
+ oldStatus: task.status,
106
+ newStatus: status,
107
+ line: targetLine,
108
+ change: {
109
+ before: lines[targetLine],
110
+ after: updatedContent.split('\n')[targetLine]
111
+ }
112
+ }
113
+
114
+ // čæ½åŠ åˆ°ę›“ę–°ę—„åæ—
115
+ appendFile(
116
+ `exports/jobs/${jobId}/logs/status-updates.jsonl`,
117
+ JSON.stringify(log) + '\n'
118
+ )
119
+ ```
120
+
121
+ ## ēŠ¶ę€ę ‡č®°ę ¼å¼
122
+
123
+ ### Markdown ä»»åŠ”åˆ—č”Øę ¼å¼
124
+
125
+ ```markdown
126
+ ## Phase 1: Foundation
127
+
128
+ ### ä»»åŠ”åˆ—č”Ø
129
+
130
+ - [ ] å®žēŽ°ę”Æä»˜ API
131
+ - [ ] ę·»åŠ å¤šč“§åøę”ÆęŒ
132
+ - [x] 集ꈐ Stripe
133
+ - [ ] 编写测试
134
+ ```
135
+
136
+ ### ę”ÆęŒēš„ēŠ¶ę€
137
+
138
+ | ēŠ¶ę€ | Markdown | čÆ“ę˜Ž |
139
+ |------|----------|------|
140
+ | pending | `- [ ]` | 待开始 |
141
+ | in-progress | `- [ ]` | čæ›č”Œäø­ļ¼ˆäøę”¹å˜ę ‡č®°ļ¼‰ |
142
+ | completed | `- [x]` | 已完成 |
143
+ | failed | `- [ ]` | å¤±č“„ļ¼ˆę¢å¤äøŗå¾…å¼€å§‹ļ¼‰ |
144
+
145
+ ### 嵌儗任劔
146
+
147
+ ```markdown
148
+ - [ ] å®žēŽ°ę”Æä»˜åŠŸčƒ½
149
+ - [x] č®¾č®”ęŽ„å£
150
+ - [x] å®žēŽ° Stripe 集ꈐ
151
+ - [ ] 添加 webhook 处理
152
+ - [ ] 编写测试
153
+ ```
154
+
155
+ **处理逻辑**:
156
+ - åŖę›“ę–°äø»ä»»åŠ”ēš„ēŠ¶ę€
157
+ - å­ä»»åŠ”ēŠ¶ę€ē”±å¼€å‘č€…ę‰‹åŠØę›“ę–°
158
+ - ęˆ–ę ¹ę®å­ä»»åŠ”å®Œęˆęƒ…å†µč‡ŖåŠØę›“ę–°äø»ä»»åŠ”
159
+
160
+ ## 使用示例
161
+
162
+ ### 示例 1ļ¼šę ‡č®°ä»»åŠ”å®Œęˆ
163
+
164
+ ```
165
+ Agent č°ƒē”Ø task-update-status:
166
+ 输兄:
167
+ - taskId: TASK-001
168
+ - jobId: 2026-02-10-1520-pricing-system
169
+ - openspecPath: openspec/changes/001-pricing-system/
170
+ - status: completed
171
+
172
+ ę‰§č”Œ:
173
+ šŸ”§ ę­„éŖ¤ 1: čÆ»å– tasks.md
174
+ ā³ ꖇ件: openspec/changes/001-pricing-system/tasks.md
175
+ ā³ ę€»č”Œę•°: 156 蔌
176
+
177
+ šŸ”§ ę­„éŖ¤ 2: 定位任劔
178
+ ā³ 任劔: TASK-001 - Develop payment-gateway capability
179
+ ā³ 引用: line 42, marker: "- [ ] Develop payment-gateway capability"
180
+ āœ… ę‰¾åˆ°: 第 42 蔌
181
+
182
+ šŸ”§ ę­„éŖ¤ 3: ę›“ę–°ēŠ¶ę€
183
+ šŸ“ äæ®ę”¹å‰: - [ ] Develop payment-gateway capability
184
+ šŸ“ äæ®ę”¹åŽ: - [x] Develop payment-gateway capability
185
+
186
+ šŸ”§ ę­„éŖ¤ 4: 写兄文件
187
+ āœ… å·²äæå­˜: tasks.md
188
+
189
+ šŸ”§ ę­„éŖ¤ 5: 记录旄志
190
+ āœ… 已记录: logs/status-updates.jsonl
191
+
192
+ ę˜¾ē¤ŗē»“ęžœ:
193
+ āœ… ēŠ¶ę€å·²ę›“ę–°
194
+
195
+ šŸ“ 曓新俔息:
196
+ - 任劔: TASK-001
197
+ - ꖇ件: tasks.md (第 42 蔌)
198
+ - ēŠ¶ę€: pending → completed
199
+ - ꠇ记: [ ] → [x]
200
+
201
+ šŸ’” 下一歄:
202
+ 继续曓新 progress.json
203
+ ```
204
+
205
+ ### 示例 2ļ¼šę‰¹é‡ę›“ę–°
206
+
207
+ ```
208
+ Agent č°ƒē”Ø task-update-status (ę‰¹é‡):
209
+ 输兄:
210
+ - taskIds: [TASK-001, TASK-002, TASK-003]
211
+ - jobId: 2026-02-10-1520-pricing-system
212
+ - openspecPath: openspec/changes/001-pricing-system/
213
+ - status: completed
214
+
215
+ ę‰§č”Œ:
216
+ šŸ”§ ę‰¹é‡ę›“ę–° 3 个任劔
217
+
218
+ ā³ TASK-001: 第 42 蔌 āœ…
219
+ ā³ TASK-002: 第 58 蔌 āœ…
220
+ ā³ TASK-003: 第 73 蔌 āœ…
221
+
222
+ ę˜¾ē¤ŗē»“ęžœ:
223
+ āœ… ę‰¹é‡ę›“ę–°å®Œęˆ
224
+
225
+ šŸ“Š ę›“ę–°ē»Ÿč®”:
226
+ - ꀻ讔: 3 个任劔
227
+ - 成功: 3 äøŖ āœ…
228
+ - 失蓄: 0 个
229
+ ```
230
+
231
+ ### 示例 3ļ¼šä»»åŠ”ęœŖę‰¾åˆ°
232
+
233
+ ```
234
+ Agent č°ƒē”Ø task-update-status:
235
+ 输兄:
236
+ - taskId: TASK-999
237
+ - jobId: 2026-02-10-1520-pricing-system
238
+ - openspecPath: openspec/changes/001-pricing-system/
239
+ - status: completed
240
+
241
+ ę‰§č”Œ:
242
+ šŸ”§ ę­„éŖ¤ 1-2: čÆ»å–å’Œå®šä½
243
+
244
+ āŒ 错误: ä»»åŠ”ęœŖę‰¾åˆ°
245
+ šŸ” 原因: tasks.md äø­ę²”ęœ‰ę‰¾åˆ° TASK-999 ēš„ę ‡č®°
246
+
247
+ ę˜¾ē¤ŗē»“ęžœ:
248
+ āŒ 曓新失蓄
249
+
250
+ šŸ’” 建议:
251
+ 1. ę£€ęŸ„ taskId 是否正甮
252
+ 2. ę£€ęŸ„ tasks.md äø­ę˜Æå¦ęœ‰åÆ¹åŗ”ä»»åŠ”
253
+ 3. ęˆ–ę‰‹åŠØę·»åŠ ä»»åŠ”ę ‡č®°
254
+ ```
255
+
256
+ ## ę™ŗčƒ½åŒ¹é…ē­–ē•„
257
+
258
+ ### 1. ē²¾ē”®åŒ¹é…ļ¼ˆä¼˜å…ˆļ¼‰
259
+
260
+ ```typescript
261
+ // 使用 mdxRef.marker ē²¾ē”®åŒ¹é…
262
+ const exactMatch = lines.findIndex(line =>
263
+ line.trim() === mdxRef.marker.trim()
264
+ )
265
+ ```
266
+
267
+ ### 2. ę ‡é¢˜åŒ¹é…
268
+
269
+ ```typescript
270
+ // ä½æē”Øä»»åŠ”ę ‡é¢˜åŒ¹é…
271
+ const titleMatch = lines.findIndex(line =>
272
+ line.includes(task.title) &&
273
+ (line.includes('- [ ]') || line.includes('- [x]'))
274
+ )
275
+ ```
276
+
277
+ ### 3. ęØ”ē³ŠåŒ¹é…
278
+
279
+ ```typescript
280
+ // ä½æē”Øå…³é”®čÆåŒ¹é…
281
+ const keywords = task.title.split(' ').filter(w => w.length > 3)
282
+ const fuzzyMatch = lines.findIndex(line =>
283
+ keywords.some(kw => line.includes(kw)) &&
284
+ (line.includes('- [ ]') || line.includes('- [x]'))
285
+ )
286
+ ```
287
+
288
+ ### 4. č”Œå·åŒ¹é…ļ¼ˆęœ€åŽę‰‹ę®µļ¼‰
289
+
290
+ ```typescript
291
+ // 使用 mdxRef.line ē›“ęŽ„å®šä½
292
+ if (mdxRef && mdxRef.line) {
293
+ const lineMatch = mdxRef.line - 1 // č½¬ę¢äøŗ 0-based index
294
+ if (lines[lineMatch].includes('- [ ]') || lines[lineMatch].includes('- [x]')) {
295
+ // ä½æē”Øčæ™äø€č”Œ
296
+ }
297
+ }
298
+ ```
299
+
300
+ ## 错误处理
301
+
302
+ ### 错误 1:tasks.md äøå­˜åœØ
303
+
304
+ ```
305
+ āŒ 错误: tasks.md ę–‡ä»¶äøå­˜åœØ
306
+ šŸ” 原因: openspec/changes/001-pricing-system/tasks.md ęœŖę‰¾åˆ°
307
+
308
+ šŸ’” 建议:
309
+ 1. ę£€ęŸ„ OpenSpec 路径
310
+ 2. 甮认 tasks.md ę–‡ä»¶å­˜åœØ
311
+ 3. é‡ę–°ē”Ÿęˆ OpenSpec
312
+ ```
313
+
314
+ ### 错误 2ļ¼šä»»åŠ”ę ‡č®°ęœŖę‰¾åˆ°
315
+
316
+ ```
317
+ āŒ 错误: ä»»åŠ”ę ‡č®°ęœŖę‰¾åˆ°
318
+ šŸ” 原因: tasks.md äø­ę²”ęœ‰ TASK-001 ēš„ę ‡č®°
319
+
320
+ šŸ’” 建议:
321
+ 1. ę£€ęŸ„ä»»åŠ”ę ‡é¢˜ę˜Æå¦åŒ¹é…
322
+ 2. ę‰‹åŠØę·»åŠ ä»»åŠ”ę ‡č®°
323
+ 3. ęˆ–ę›“ę–° mdxRef 俔息
324
+ ```
325
+
326
+ ### 错误 3ļ¼šę–‡ä»¶å†™å…„å¤±č“„
327
+
328
+ ```
329
+ āŒ 错误: 文件写兄失蓄
330
+ šŸ” 原因: ę²”ęœ‰å†™å…„ęƒé™
331
+
332
+ šŸ’” 建议:
333
+ 1. ę£€ęŸ„ę–‡ä»¶ęƒé™
334
+ 2. ē”®č®¤ę–‡ä»¶ęœŖč¢«é”å®š
335
+ ```
336
+
337
+ ## ę³Øę„äŗ‹é”¹
338
+
339
+ 1. **ē²¾ē”®åŒ¹é…** - ä¼˜å…ˆä½æē”Ø mdxRef.marker ē²¾ē”®åŒ¹é…
340
+ 2. **äæęŒę ¼å¼** - åŖäæ®ę”¹ēŠ¶ę€ę ‡č®°ļ¼ŒäæęŒå…¶ä»–ę ¼å¼äøå˜
341
+ 3. **åŽŸå­ę“ä½œ** - čÆ»å–-修改-å†™å…„ä½œäøŗåŽŸå­ę“ä½œ
342
+ 4. **旄志记录** - č®°å½•ęÆę¬”ę›“ę–°ļ¼Œä¾æäŗŽčæ½ęŗÆ
343
+ 5. **幂等性** - å¤šę¬”č°ƒē”Øē»“ęžœäø€č‡“
344
+
345
+ ## 相关文件
346
+
347
+ - `openspec/changes/<change-id>/tasks.md` - OpenSpec ä»»åŠ”åˆ—č”Ø
348
+ - `exports/jobs/<job-id>/specs/tasks.json` - ä»»åŠ”čÆ¦ęƒ…
349
+ - `exports/jobs/<job-id>/logs/status-updates.jsonl` - 曓新旄志
@@ -0,0 +1,192 @@
1
+ #!/usr/bin/env node
2
+ /**
3
+ * Update Task Status in OpenSpec tasks.md
4
+ *
5
+ * This script updates task status in OpenSpec tasks.md file:
6
+ * - Mark task as completed: `- [ ]` → `- [x]`
7
+ * - Update task metadata (completion time, notes)
8
+ *
9
+ * Usage:
10
+ * npx tsx update-task-status.ts \
11
+ * --openspec <openspec-path> \
12
+ * --task <task-id> \
13
+ * --status <completed|in_progress|failed>
14
+ *
15
+ * Example:
16
+ * npx tsx update-task-status.ts \
17
+ * --openspec openspec/changes/001-pricing-system/ \
18
+ * --task TASK-001 \
19
+ * --status completed
20
+ */
21
+
22
+ import fs from 'fs';
23
+ import path from 'path';
24
+ import { fileURLToPath } from 'url';
25
+
26
+ const __filename = fileURLToPath(import.meta.url);
27
+ const __dirname = path.dirname(__filename);
28
+
29
+ // ============================================================================
30
+ // Types
31
+ // ============================================================================
32
+
33
+ type TaskStatus = 'completed' | 'in_progress' | 'failed' | 'pending';
34
+
35
+ interface UpdateOptions {
36
+ openspecPath: string;
37
+ taskId: string;
38
+ status: TaskStatus;
39
+ notes?: string;
40
+ }
41
+
42
+ // ============================================================================
43
+ // CLI Arguments
44
+ // ============================================================================
45
+
46
+ function parseArgs(): UpdateOptions {
47
+ const args = process.argv.slice(2);
48
+ const result: any = {};
49
+
50
+ for (let i = 0; i < args.length; i += 2) {
51
+ const key = args[i].replace('--', '');
52
+ const value = args[i + 1];
53
+ result[key] = value;
54
+ }
55
+
56
+ if (!result.openspec || !result.task || !result.status) {
57
+ console.error('āŒ Missing required arguments');
58
+ console.error('Usage: update-task-status.ts --openspec <path> --task <id> --status <status>');
59
+ process.exit(1);
60
+ }
61
+
62
+ return {
63
+ openspecPath: result.openspec,
64
+ taskId: result.task,
65
+ status: result.status as TaskStatus,
66
+ notes: result.notes,
67
+ };
68
+ }
69
+
70
+ // ============================================================================
71
+ // OpenSpec tasks.md Operations
72
+ // ============================================================================
73
+
74
+ function readTasksFile(openspecPath: string): string {
75
+ const tasksPath = path.join(openspecPath, 'tasks.md');
76
+
77
+ if (!fs.existsSync(tasksPath)) {
78
+ throw new Error(`tasks.md not found: ${tasksPath}`);
79
+ }
80
+
81
+ return fs.readFileSync(tasksPath, 'utf-8');
82
+ }
83
+
84
+ function writeTasksFile(openspecPath: string, content: string): void {
85
+ const tasksPath = path.join(openspecPath, 'tasks.md');
86
+ fs.writeFileSync(tasksPath, content, 'utf-8');
87
+ }
88
+
89
+ function updateTaskStatus(content: string, taskId: string, status: TaskStatus, notes?: string): string {
90
+ const lines = content.split('\n');
91
+ let updated = false;
92
+ let inTask = false;
93
+ let taskIndent = 0;
94
+
95
+ for (let i = 0; i < lines.length; i++) {
96
+ const line = lines[i];
97
+
98
+ // Find task by ID (in comment or heading)
99
+ if (line.includes(taskId)) {
100
+ inTask = true;
101
+ taskIndent = line.search(/\S/); // Get indentation level
102
+ continue;
103
+ }
104
+
105
+ // Update checkbox if we're in the target task
106
+ if (inTask && line.match(/^[\s]*-\s+\[[ x]\]/)) {
107
+ const currentIndent = line.search(/\S/);
108
+
109
+ // Check if this is a subtask (more indented) or next task (same/less indented)
110
+ if (currentIndent > taskIndent) {
111
+ // This is a subtask, skip it
112
+ continue;
113
+ } else if (currentIndent === taskIndent) {
114
+ // This is the task checkbox
115
+ if (status === 'completed') {
116
+ lines[i] = line.replace(/- \[ \]/, '- [x]');
117
+ } else if (status === 'in_progress') {
118
+ lines[i] = line.replace(/- \[x\]/, '- [ ]');
119
+ } else if (status === 'failed') {
120
+ lines[i] = line.replace(/- \[ \]/, '- [x]') + ' āŒ';
121
+ }
122
+
123
+ // Add completion note if provided
124
+ if (notes && status === 'completed') {
125
+ const noteIndent = ' '.repeat(currentIndent + 2);
126
+ lines.splice(i + 1, 0, `${noteIndent}> āœ… Completed: ${notes}`);
127
+ }
128
+
129
+ updated = true;
130
+ inTask = false;
131
+ break;
132
+ } else {
133
+ // Next task at same or lower level, stop
134
+ inTask = false;
135
+ break;
136
+ }
137
+ }
138
+ }
139
+
140
+ if (!updated) {
141
+ throw new Error(`Task ${taskId} not found in tasks.md`);
142
+ }
143
+
144
+ return lines.join('\n');
145
+ }
146
+
147
+ // ============================================================================
148
+ // Main
149
+ // ============================================================================
150
+
151
+ async function main() {
152
+ console.log('šŸ”§ Updating task status in OpenSpec...\n');
153
+
154
+ const options = parseArgs();
155
+
156
+ console.log('šŸ“„ Input:');
157
+ console.log(` - OpenSpec: ${options.openspecPath}`);
158
+ console.log(` - Task ID: ${options.taskId}`);
159
+ console.log(` - Status: ${options.status}`);
160
+ if (options.notes) {
161
+ console.log(` - Notes: ${options.notes}`);
162
+ }
163
+ console.log('');
164
+
165
+ // Step 1: Read tasks.md
166
+ console.log('šŸ“– Step 1/3: Reading tasks.md...');
167
+ const content = readTasksFile(options.openspecPath);
168
+ console.log('āœ… Read\n');
169
+
170
+ // Step 2: Update task status
171
+ console.log('šŸ”§ Step 2/3: Updating task status...');
172
+ const updatedContent = updateTaskStatus(
173
+ content,
174
+ options.taskId,
175
+ options.status,
176
+ options.notes
177
+ );
178
+ console.log('āœ… Updated\n');
179
+
180
+ // Step 3: Write back
181
+ console.log('šŸ’¾ Step 3/3: Writing tasks.md...');
182
+ writeTasksFile(options.openspecPath, updatedContent);
183
+ console.log('āœ… Written\n');
184
+
185
+ console.log('šŸŽ‰ Done!');
186
+ console.log(`\nāœ… Task ${options.taskId} marked as ${options.status}`);
187
+ }
188
+
189
+ main().catch(error => {
190
+ console.error('āŒ Error:', error.message);
191
+ process.exit(1);
192
+ });