openspecui 0.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 (311) hide show
  1. package/.gitmodules +3 -0
  2. package/CHAT.md +3 -0
  3. package/package.json +12 -0
  4. package/references/openspec/.changeset/README.md +6 -0
  5. package/references/openspec/.changeset/config.json +12 -0
  6. package/references/openspec/.coderabbit.yaml +11 -0
  7. package/references/openspec/.devcontainer/README.md +92 -0
  8. package/references/openspec/.devcontainer/devcontainer.json +68 -0
  9. package/references/openspec/.github/CODEOWNERS +2 -0
  10. package/references/openspec/.github/workflows/ci.yml +222 -0
  11. package/references/openspec/.github/workflows/release-prepare.yml +50 -0
  12. package/references/openspec/AGENTS.md +18 -0
  13. package/references/openspec/CHANGELOG.md +205 -0
  14. package/references/openspec/LICENSE +22 -0
  15. package/references/openspec/README.md +374 -0
  16. package/references/openspec/assets/openspec_dashboard.png +0 -0
  17. package/references/openspec/assets/openspec_pixel_dark.svg +89 -0
  18. package/references/openspec/assets/openspec_pixel_light.svg +89 -0
  19. package/references/openspec/bin/openspec.js +3 -0
  20. package/references/openspec/build.js +31 -0
  21. package/references/openspec/openspec/AGENTS.md +454 -0
  22. package/references/openspec/openspec/changes/IMPLEMENTATION_ORDER.md +68 -0
  23. package/references/openspec/openspec/changes/add-antigravity-support/proposal.md +11 -0
  24. package/references/openspec/openspec/changes/add-antigravity-support/specs/cli-init/spec.md +9 -0
  25. package/references/openspec/openspec/changes/add-antigravity-support/specs/cli-update/spec.md +8 -0
  26. package/references/openspec/openspec/changes/add-antigravity-support/tasks.md +12 -0
  27. package/references/openspec/openspec/changes/add-scaffold-command/proposal.md +11 -0
  28. package/references/openspec/openspec/changes/add-scaffold-command/specs/cli-scaffold/spec.md +36 -0
  29. package/references/openspec/openspec/changes/add-scaffold-command/tasks.md +12 -0
  30. package/references/openspec/openspec/changes/archive/2025-01-11-add-update-command/design.md +86 -0
  31. package/references/openspec/openspec/changes/archive/2025-01-11-add-update-command/proposal.md +29 -0
  32. package/references/openspec/openspec/changes/archive/2025-01-11-add-update-command/specs/cli-update/spec.md +59 -0
  33. package/references/openspec/openspec/changes/archive/2025-01-11-add-update-command/tasks.md +20 -0
  34. package/references/openspec/openspec/changes/archive/2025-01-13-add-list-command/proposal.md +20 -0
  35. package/references/openspec/openspec/changes/archive/2025-01-13-add-list-command/specs/cli-list/spec.md +69 -0
  36. package/references/openspec/openspec/changes/archive/2025-01-13-add-list-command/tasks.md +26 -0
  37. package/references/openspec/openspec/changes/archive/2025-08-05-initialize-typescript-project/design.md +64 -0
  38. package/references/openspec/openspec/changes/archive/2025-08-05-initialize-typescript-project/proposal.md +18 -0
  39. package/references/openspec/openspec/changes/archive/2025-08-05-initialize-typescript-project/tasks.md +25 -0
  40. package/references/openspec/openspec/changes/archive/2025-08-06-add-init-command/design.md +104 -0
  41. package/references/openspec/openspec/changes/archive/2025-08-06-add-init-command/proposal.md +30 -0
  42. package/references/openspec/openspec/changes/archive/2025-08-06-add-init-command/specs/cli-init/spec.md +148 -0
  43. package/references/openspec/openspec/changes/archive/2025-08-06-add-init-command/tasks.md +38 -0
  44. package/references/openspec/openspec/changes/archive/2025-08-06-adopt-future-state-storage/proposal.md +24 -0
  45. package/references/openspec/openspec/changes/archive/2025-08-06-adopt-future-state-storage/specs/openspec-conventions/spec.md +120 -0
  46. package/references/openspec/openspec/changes/archive/2025-08-06-adopt-future-state-storage/tasks.md +38 -0
  47. package/references/openspec/openspec/changes/archive/2025-08-11-add-complexity-guidelines/proposal.md +13 -0
  48. package/references/openspec/openspec/changes/archive/2025-08-11-add-complexity-guidelines/specs/openspec-docs/README.md +472 -0
  49. package/references/openspec/openspec/changes/archive/2025-08-11-add-complexity-guidelines/tasks.md +9 -0
  50. package/references/openspec/openspec/changes/archive/2025-08-13-add-archive-command/proposal.md +15 -0
  51. package/references/openspec/openspec/changes/archive/2025-08-13-add-archive-command/specs/cli-archive/spec.md +111 -0
  52. package/references/openspec/openspec/changes/archive/2025-08-13-add-archive-command/tasks.md +44 -0
  53. package/references/openspec/openspec/changes/archive/2025-08-13-add-diff-command/proposal.md +19 -0
  54. package/references/openspec/openspec/changes/archive/2025-08-13-add-diff-command/specs/cli-diff/spec.md +77 -0
  55. package/references/openspec/openspec/changes/archive/2025-08-13-add-diff-command/tasks.md +23 -0
  56. package/references/openspec/openspec/changes/archive/2025-08-19-add-change-commands/design.md +56 -0
  57. package/references/openspec/openspec/changes/archive/2025-08-19-add-change-commands/proposal.md +17 -0
  58. package/references/openspec/openspec/changes/archive/2025-08-19-add-change-commands/specs/cli-change/spec.md +48 -0
  59. package/references/openspec/openspec/changes/archive/2025-08-19-add-change-commands/specs/cli-list/spec.md +12 -0
  60. package/references/openspec/openspec/changes/archive/2025-08-19-add-change-commands/tasks.md +34 -0
  61. package/references/openspec/openspec/changes/archive/2025-08-19-add-interactive-show-command/proposal.md +20 -0
  62. package/references/openspec/openspec/changes/archive/2025-08-19-add-interactive-show-command/specs/cli-change/spec.md +23 -0
  63. package/references/openspec/openspec/changes/archive/2025-08-19-add-interactive-show-command/specs/cli-show/spec.md +83 -0
  64. package/references/openspec/openspec/changes/archive/2025-08-19-add-interactive-show-command/specs/cli-spec/spec.md +23 -0
  65. package/references/openspec/openspec/changes/archive/2025-08-19-add-interactive-show-command/tasks.md +142 -0
  66. package/references/openspec/openspec/changes/archive/2025-08-19-add-skip-specs-archive-option/proposal.md +13 -0
  67. package/references/openspec/openspec/changes/archive/2025-08-19-add-skip-specs-archive-option/specs/cli-archive/spec.md +191 -0
  68. package/references/openspec/openspec/changes/archive/2025-08-19-add-skip-specs-archive-option/tasks.md +57 -0
  69. package/references/openspec/openspec/changes/archive/2025-08-19-add-spec-commands/design.md +45 -0
  70. package/references/openspec/openspec/changes/archive/2025-08-19-add-spec-commands/proposal.md +19 -0
  71. package/references/openspec/openspec/changes/archive/2025-08-19-add-spec-commands/specs/cli-spec/spec.md +43 -0
  72. package/references/openspec/openspec/changes/archive/2025-08-19-add-spec-commands/tasks.md +22 -0
  73. package/references/openspec/openspec/changes/archive/2025-08-19-add-zod-validation/design.md +104 -0
  74. package/references/openspec/openspec/changes/archive/2025-08-19-add-zod-validation/proposal.md +22 -0
  75. package/references/openspec/openspec/changes/archive/2025-08-19-add-zod-validation/specs/cli-archive/spec.md +18 -0
  76. package/references/openspec/openspec/changes/archive/2025-08-19-add-zod-validation/specs/cli-diff/spec.md +12 -0
  77. package/references/openspec/openspec/changes/archive/2025-08-19-add-zod-validation/tasks.md +59 -0
  78. package/references/openspec/openspec/changes/archive/2025-08-19-adopt-delta-based-changes/proposal.md +93 -0
  79. package/references/openspec/openspec/changes/archive/2025-08-19-adopt-delta-based-changes/specs/cli-archive/spec.md +48 -0
  80. package/references/openspec/openspec/changes/archive/2025-08-19-adopt-delta-based-changes/specs/cli-diff/spec.md +45 -0
  81. package/references/openspec/openspec/changes/archive/2025-08-19-adopt-delta-based-changes/specs/openspec-conventions/spec.md +101 -0
  82. package/references/openspec/openspec/changes/archive/2025-08-19-adopt-delta-based-changes/tasks.md +55 -0
  83. package/references/openspec/openspec/changes/archive/2025-08-19-adopt-verb-noun-cli-structure/design.md +19 -0
  84. package/references/openspec/openspec/changes/archive/2025-08-19-adopt-verb-noun-cli-structure/proposal.md +67 -0
  85. package/references/openspec/openspec/changes/archive/2025-08-19-adopt-verb-noun-cli-structure/specs/cli-list/spec.md +57 -0
  86. package/references/openspec/openspec/changes/archive/2025-08-19-adopt-verb-noun-cli-structure/specs/openspec-conventions/spec.md +23 -0
  87. package/references/openspec/openspec/changes/archive/2025-08-19-adopt-verb-noun-cli-structure/tasks.md +27 -0
  88. package/references/openspec/openspec/changes/archive/2025-08-19-bulk-validation-interactive-selection/proposal.md +20 -0
  89. package/references/openspec/openspec/changes/archive/2025-08-19-bulk-validation-interactive-selection/specs/cli-change/spec.md +22 -0
  90. package/references/openspec/openspec/changes/archive/2025-08-19-bulk-validation-interactive-selection/specs/cli-spec/spec.md +23 -0
  91. package/references/openspec/openspec/changes/archive/2025-08-19-bulk-validation-interactive-selection/specs/cli-validate/spec.md +149 -0
  92. package/references/openspec/openspec/changes/archive/2025-08-19-bulk-validation-interactive-selection/tasks.md +81 -0
  93. package/references/openspec/openspec/changes/archive/2025-08-19-fix-update-tool-selection/proposal.md +40 -0
  94. package/references/openspec/openspec/changes/archive/2025-08-19-fix-update-tool-selection/specs/cli-update/spec.md +23 -0
  95. package/references/openspec/openspec/changes/archive/2025-08-19-fix-update-tool-selection/tasks.md +21 -0
  96. package/references/openspec/openspec/changes/archive/2025-08-19-improve-validate-error-messages/proposal.md +25 -0
  97. package/references/openspec/openspec/changes/archive/2025-08-19-improve-validate-error-messages/specs/cli-validate/spec.md +55 -0
  98. package/references/openspec/openspec/changes/archive/2025-08-19-improve-validate-error-messages/tasks.md +21 -0
  99. package/references/openspec/openspec/changes/archive/2025-08-19-structured-spec-format/proposal.md +36 -0
  100. package/references/openspec/openspec/changes/archive/2025-08-19-structured-spec-format/specs/openspec-conventions/spec.md +192 -0
  101. package/references/openspec/openspec/changes/archive/2025-08-19-structured-spec-format/tasks.md +19 -0
  102. package/references/openspec/openspec/changes/archive/2025-09-12-add-view-dashboard-command/proposal.md +38 -0
  103. package/references/openspec/openspec/changes/archive/2025-09-12-add-view-dashboard-command/specs/cli-view/spec.md +109 -0
  104. package/references/openspec/openspec/changes/archive/2025-09-12-add-view-dashboard-command/tasks.md +47 -0
  105. package/references/openspec/openspec/changes/archive/2025-09-29-add-agents-md-config/proposal.md +28 -0
  106. package/references/openspec/openspec/changes/archive/2025-09-29-add-agents-md-config/specs/cli-init/spec.md +71 -0
  107. package/references/openspec/openspec/changes/archive/2025-09-29-add-agents-md-config/specs/cli-update/spec.md +41 -0
  108. package/references/openspec/openspec/changes/archive/2025-09-29-add-agents-md-config/tasks.md +17 -0
  109. package/references/openspec/openspec/changes/archive/2025-09-29-add-multi-agent-init/proposal.md +35 -0
  110. package/references/openspec/openspec/changes/archive/2025-09-29-add-multi-agent-init/specs/cli-init/spec.md +45 -0
  111. package/references/openspec/openspec/changes/archive/2025-09-29-add-multi-agent-init/tasks.md +16 -0
  112. package/references/openspec/openspec/changes/archive/2025-09-29-add-slash-command-support/proposal.md +119 -0
  113. package/references/openspec/openspec/changes/archive/2025-09-29-add-slash-command-support/specs/cli-init/spec.md +21 -0
  114. package/references/openspec/openspec/changes/archive/2025-09-29-add-slash-command-support/specs/cli-update/spec.md +22 -0
  115. package/references/openspec/openspec/changes/archive/2025-09-29-add-slash-command-support/tasks.md +20 -0
  116. package/references/openspec/openspec/changes/archive/2025-09-29-improve-cli-e2e-plan/proposal.md +19 -0
  117. package/references/openspec/openspec/changes/archive/2025-09-29-improve-cli-e2e-plan/tasks.md +9 -0
  118. package/references/openspec/openspec/changes/archive/2025-09-29-improve-deterministic-tests/proposal.md +78 -0
  119. package/references/openspec/openspec/changes/archive/2025-09-29-improve-deterministic-tests/tasks.md +25 -0
  120. package/references/openspec/openspec/changes/archive/2025-09-29-improve-init-onboarding/proposal.md +13 -0
  121. package/references/openspec/openspec/changes/archive/2025-09-29-improve-init-onboarding/specs/cli-init/spec.md +92 -0
  122. package/references/openspec/openspec/changes/archive/2025-09-29-improve-init-onboarding/tasks.md +12 -0
  123. package/references/openspec/openspec/changes/archive/2025-09-29-remove-diff-command/proposal.md +81 -0
  124. package/references/openspec/openspec/changes/archive/2025-09-29-remove-diff-command/tasks.md +37 -0
  125. package/references/openspec/openspec/changes/archive/2025-09-29-sort-active-changes-by-progress/proposal.md +25 -0
  126. package/references/openspec/openspec/changes/archive/2025-09-29-sort-active-changes-by-progress/specs/cli-view/spec.md +9 -0
  127. package/references/openspec/openspec/changes/archive/2025-09-29-sort-active-changes-by-progress/tasks.md +8 -0
  128. package/references/openspec/openspec/changes/archive/2025-09-29-update-agent-file-name/proposal.md +29 -0
  129. package/references/openspec/openspec/changes/archive/2025-09-29-update-agent-file-name/specs/cli-init/spec.md +40 -0
  130. package/references/openspec/openspec/changes/archive/2025-09-29-update-agent-file-name/specs/cli-update/spec.md +22 -0
  131. package/references/openspec/openspec/changes/archive/2025-09-29-update-agent-file-name/specs/openspec-conventions/spec.md +27 -0
  132. package/references/openspec/openspec/changes/archive/2025-09-29-update-agent-file-name/tasks.md +22 -0
  133. package/references/openspec/openspec/changes/archive/2025-09-29-update-agent-instructions/design.md +130 -0
  134. package/references/openspec/openspec/changes/archive/2025-09-29-update-agent-instructions/proposal.md +117 -0
  135. package/references/openspec/openspec/changes/archive/2025-09-29-update-agent-instructions/tasks.md +69 -0
  136. package/references/openspec/openspec/changes/archive/2025-09-29-update-markdown-parser-crlf/proposal.md +19 -0
  137. package/references/openspec/openspec/changes/archive/2025-09-29-update-markdown-parser-crlf/specs/cli-validate/spec.md +9 -0
  138. package/references/openspec/openspec/changes/archive/2025-09-29-update-markdown-parser-crlf/tasks.md +11 -0
  139. package/references/openspec/openspec/changes/archive/2025-10-14-add-codex-slash-command-support/proposal.md +25 -0
  140. package/references/openspec/openspec/changes/archive/2025-10-14-add-codex-slash-command-support/specs/cli-init/spec.md +56 -0
  141. package/references/openspec/openspec/changes/archive/2025-10-14-add-codex-slash-command-support/specs/cli-update/spec.md +41 -0
  142. package/references/openspec/openspec/changes/archive/2025-10-14-add-codex-slash-command-support/tasks.md +19 -0
  143. package/references/openspec/openspec/changes/archive/2025-10-14-add-github-copilot-prompts/proposal.md +25 -0
  144. package/references/openspec/openspec/changes/archive/2025-10-14-add-github-copilot-prompts/specs/cli-init/spec.md +48 -0
  145. package/references/openspec/openspec/changes/archive/2025-10-14-add-github-copilot-prompts/specs/cli-update/spec.md +48 -0
  146. package/references/openspec/openspec/changes/archive/2025-10-14-add-github-copilot-prompts/tasks.md +30 -0
  147. package/references/openspec/openspec/changes/archive/2025-10-14-add-kilocode-workflows/proposal.md +17 -0
  148. package/references/openspec/openspec/changes/archive/2025-10-14-add-kilocode-workflows/specs/cli-init/spec.md +43 -0
  149. package/references/openspec/openspec/changes/archive/2025-10-14-add-kilocode-workflows/specs/cli-update/spec.md +27 -0
  150. package/references/openspec/openspec/changes/archive/2025-10-14-add-kilocode-workflows/tasks.md +15 -0
  151. package/references/openspec/openspec/changes/archive/2025-10-14-add-non-interactive-init-options/proposal.md +12 -0
  152. package/references/openspec/openspec/changes/archive/2025-10-14-add-non-interactive-init-options/specs/cli-init/spec.md +39 -0
  153. package/references/openspec/openspec/changes/archive/2025-10-14-add-non-interactive-init-options/tasks.md +17 -0
  154. package/references/openspec/openspec/changes/archive/2025-10-14-add-windsurf-workflows/proposal.md +17 -0
  155. package/references/openspec/openspec/changes/archive/2025-10-14-add-windsurf-workflows/specs/cli-init/spec.md +42 -0
  156. package/references/openspec/openspec/changes/archive/2025-10-14-add-windsurf-workflows/specs/cli-update/spec.md +27 -0
  157. package/references/openspec/openspec/changes/archive/2025-10-14-add-windsurf-workflows/tasks.md +17 -0
  158. package/references/openspec/openspec/changes/archive/2025-10-14-enhance-validation-error-messages/proposal.md +12 -0
  159. package/references/openspec/openspec/changes/archive/2025-10-14-enhance-validation-error-messages/specs/cli-validate/spec.md +39 -0
  160. package/references/openspec/openspec/changes/archive/2025-10-14-enhance-validation-error-messages/tasks.md +12 -0
  161. package/references/openspec/openspec/changes/archive/2025-10-14-improve-agent-instruction-usability/proposal.md +12 -0
  162. package/references/openspec/openspec/changes/archive/2025-10-14-improve-agent-instruction-usability/specs/docs-agent-instructions/spec.md +33 -0
  163. package/references/openspec/openspec/changes/archive/2025-10-14-improve-agent-instruction-usability/tasks.md +11 -0
  164. package/references/openspec/openspec/changes/archive/2025-10-14-slim-root-agents-file/proposal.md +13 -0
  165. package/references/openspec/openspec/changes/archive/2025-10-14-slim-root-agents-file/tasks.md +15 -0
  166. package/references/openspec/openspec/changes/archive/2025-10-14-update-cli-init-enter-selection/proposal.md +14 -0
  167. package/references/openspec/openspec/changes/archive/2025-10-14-update-cli-init-enter-selection/specs/cli-init/spec.md +10 -0
  168. package/references/openspec/openspec/changes/archive/2025-10-14-update-cli-init-enter-selection/tasks.md +8 -0
  169. package/references/openspec/openspec/changes/archive/2025-10-14-update-cli-init-root-agents/proposal.md +15 -0
  170. package/references/openspec/openspec/changes/archive/2025-10-14-update-cli-init-root-agents/specs/cli-init/spec.md +32 -0
  171. package/references/openspec/openspec/changes/archive/2025-10-14-update-cli-init-root-agents/specs/cli-update/spec.md +10 -0
  172. package/references/openspec/openspec/changes/archive/2025-10-14-update-cli-init-root-agents/tasks.md +11 -0
  173. package/references/openspec/openspec/changes/archive/2025-10-14-update-release-automation/proposal.md +49 -0
  174. package/references/openspec/openspec/changes/archive/2025-10-14-update-release-automation/tasks.md +12 -0
  175. package/references/openspec/openspec/changes/archive/2025-10-22-add-archive-command-arguments/proposal.md +17 -0
  176. package/references/openspec/openspec/changes/archive/2025-10-22-add-archive-command-arguments/specs/cli-update/spec.md +32 -0
  177. package/references/openspec/openspec/changes/archive/2025-10-22-add-archive-command-arguments/tasks.md +15 -0
  178. package/references/openspec/openspec/changes/archive/2025-10-22-add-cline-support/proposal.md +15 -0
  179. package/references/openspec/openspec/changes/archive/2025-10-22-add-cline-support/specs/cli-init/spec.md +97 -0
  180. package/references/openspec/openspec/changes/archive/2025-10-22-add-cline-support/tasks.md +19 -0
  181. package/references/openspec/openspec/changes/archive/2025-10-22-add-crush-support/proposal.md +13 -0
  182. package/references/openspec/openspec/changes/archive/2025-10-22-add-crush-support/specs/cli-init/spec.md +67 -0
  183. package/references/openspec/openspec/changes/archive/2025-10-22-add-crush-support/tasks.md +7 -0
  184. package/references/openspec/openspec/changes/archive/2025-10-22-add-factory-slash-commands/proposal.md +12 -0
  185. package/references/openspec/openspec/changes/archive/2025-10-22-add-factory-slash-commands/specs/cli-init/spec.md +54 -0
  186. package/references/openspec/openspec/changes/archive/2025-10-22-add-factory-slash-commands/specs/cli-update/spec.md +54 -0
  187. package/references/openspec/openspec/changes/archive/2025-10-22-add-factory-slash-commands/tasks.md +11 -0
  188. package/references/openspec/openspec/changes/fix-cline-workflows-implementation/proposal.md +13 -0
  189. package/references/openspec/openspec/changes/fix-cline-workflows-implementation/specs/cli-init/spec.md +11 -0
  190. package/references/openspec/openspec/changes/fix-cline-workflows-implementation/tasks.md +13 -0
  191. package/references/openspec/openspec/changes/make-validation-scope-aware/proposal.md +12 -0
  192. package/references/openspec/openspec/changes/make-validation-scope-aware/specs/cli-validate/spec.md +25 -0
  193. package/references/openspec/openspec/changes/make-validation-scope-aware/tasks.md +16 -0
  194. package/references/openspec/openspec/project.md +53 -0
  195. package/references/openspec/openspec/specs/cli-archive/spec.md +210 -0
  196. package/references/openspec/openspec/specs/cli-change/spec.md +91 -0
  197. package/references/openspec/openspec/specs/cli-init/spec.md +311 -0
  198. package/references/openspec/openspec/specs/cli-list/spec.md +103 -0
  199. package/references/openspec/openspec/specs/cli-show/spec.md +85 -0
  200. package/references/openspec/openspec/specs/cli-spec/spec.md +87 -0
  201. package/references/openspec/openspec/specs/cli-update/spec.md +190 -0
  202. package/references/openspec/openspec/specs/cli-validate/spec.md +218 -0
  203. package/references/openspec/openspec/specs/cli-view/spec.md +105 -0
  204. package/references/openspec/openspec/specs/docs-agent-instructions/spec.md +38 -0
  205. package/references/openspec/openspec/specs/openspec-conventions/spec.md +474 -0
  206. package/references/openspec/openspec-parallel-merge-plan.md +98 -0
  207. package/references/openspec/package.json +73 -0
  208. package/references/openspec/pnpm-lock.yaml +2324 -0
  209. package/references/openspec/scripts/pack-version-check.mjs +111 -0
  210. package/references/openspec/src/cli/index.ts +253 -0
  211. package/references/openspec/src/commands/change.ts +291 -0
  212. package/references/openspec/src/commands/show.ts +139 -0
  213. package/references/openspec/src/commands/spec.ts +250 -0
  214. package/references/openspec/src/commands/validate.ts +305 -0
  215. package/references/openspec/src/core/archive.ts +606 -0
  216. package/references/openspec/src/core/config.ts +41 -0
  217. package/references/openspec/src/core/configurators/agents.ts +23 -0
  218. package/references/openspec/src/core/configurators/base.ts +6 -0
  219. package/references/openspec/src/core/configurators/claude.ts +23 -0
  220. package/references/openspec/src/core/configurators/cline.ts +23 -0
  221. package/references/openspec/src/core/configurators/codebuddy.ts +24 -0
  222. package/references/openspec/src/core/configurators/costrict.ts +23 -0
  223. package/references/openspec/src/core/configurators/iflow.ts +23 -0
  224. package/references/openspec/src/core/configurators/qoder.ts +53 -0
  225. package/references/openspec/src/core/configurators/qwen.ts +47 -0
  226. package/references/openspec/src/core/configurators/registry.ts +49 -0
  227. package/references/openspec/src/core/configurators/slash/amazon-q.ts +51 -0
  228. package/references/openspec/src/core/configurators/slash/antigravity.ts +28 -0
  229. package/references/openspec/src/core/configurators/slash/auggie.ts +37 -0
  230. package/references/openspec/src/core/configurators/slash/base.ts +95 -0
  231. package/references/openspec/src/core/configurators/slash/claude.ts +42 -0
  232. package/references/openspec/src/core/configurators/slash/cline.ts +27 -0
  233. package/references/openspec/src/core/configurators/slash/codebuddy.ts +43 -0
  234. package/references/openspec/src/core/configurators/slash/codex.ts +126 -0
  235. package/references/openspec/src/core/configurators/slash/costrict.ts +36 -0
  236. package/references/openspec/src/core/configurators/slash/crush.ts +42 -0
  237. package/references/openspec/src/core/configurators/slash/cursor.ts +42 -0
  238. package/references/openspec/src/core/configurators/slash/factory.ts +41 -0
  239. package/references/openspec/src/core/configurators/slash/gemini.ts +27 -0
  240. package/references/openspec/src/core/configurators/slash/github-copilot.ts +39 -0
  241. package/references/openspec/src/core/configurators/slash/iflow.ts +42 -0
  242. package/references/openspec/src/core/configurators/slash/kilocode.ts +21 -0
  243. package/references/openspec/src/core/configurators/slash/opencode.ts +83 -0
  244. package/references/openspec/src/core/configurators/slash/qoder.ts +84 -0
  245. package/references/openspec/src/core/configurators/slash/qwen.ts +55 -0
  246. package/references/openspec/src/core/configurators/slash/registry.ts +81 -0
  247. package/references/openspec/src/core/configurators/slash/roocode.ts +27 -0
  248. package/references/openspec/src/core/configurators/slash/toml-base.ts +66 -0
  249. package/references/openspec/src/core/configurators/slash/windsurf.ts +27 -0
  250. package/references/openspec/src/core/converters/json-converter.ts +61 -0
  251. package/references/openspec/src/core/index.ts +2 -0
  252. package/references/openspec/src/core/init.ts +986 -0
  253. package/references/openspec/src/core/list.ts +104 -0
  254. package/references/openspec/src/core/parsers/change-parser.ts +234 -0
  255. package/references/openspec/src/core/parsers/markdown-parser.ts +237 -0
  256. package/references/openspec/src/core/parsers/requirement-blocks.ts +234 -0
  257. package/references/openspec/src/core/schemas/base.schema.ts +20 -0
  258. package/references/openspec/src/core/schemas/change.schema.ts +42 -0
  259. package/references/openspec/src/core/schemas/index.ts +20 -0
  260. package/references/openspec/src/core/schemas/spec.schema.ts +17 -0
  261. package/references/openspec/src/core/styles/palette.ts +8 -0
  262. package/references/openspec/src/core/templates/agents-root-stub.ts +16 -0
  263. package/references/openspec/src/core/templates/agents-template.ts +457 -0
  264. package/references/openspec/src/core/templates/claude-template.ts +1 -0
  265. package/references/openspec/src/core/templates/cline-template.ts +1 -0
  266. package/references/openspec/src/core/templates/costrict-template.ts +1 -0
  267. package/references/openspec/src/core/templates/index.ts +50 -0
  268. package/references/openspec/src/core/templates/project-template.ts +38 -0
  269. package/references/openspec/src/core/templates/slash-command-templates.ts +60 -0
  270. package/references/openspec/src/core/update.ts +129 -0
  271. package/references/openspec/src/core/validation/constants.ts +48 -0
  272. package/references/openspec/src/core/validation/types.ts +19 -0
  273. package/references/openspec/src/core/validation/validator.ts +448 -0
  274. package/references/openspec/src/core/view.ts +189 -0
  275. package/references/openspec/src/index.ts +2 -0
  276. package/references/openspec/src/utils/file-system.ts +187 -0
  277. package/references/openspec/src/utils/index.ts +2 -0
  278. package/references/openspec/src/utils/interactive.ts +7 -0
  279. package/references/openspec/src/utils/item-discovery.ts +45 -0
  280. package/references/openspec/src/utils/match.ts +26 -0
  281. package/references/openspec/src/utils/task-progress.ts +43 -0
  282. package/references/openspec/test/cli-e2e/basic.test.ts +156 -0
  283. package/references/openspec/test/commands/change.interactive-show.test.ts +45 -0
  284. package/references/openspec/test/commands/change.interactive-validate.test.ts +48 -0
  285. package/references/openspec/test/commands/show.test.ts +123 -0
  286. package/references/openspec/test/commands/spec.interactive-show.test.ts +44 -0
  287. package/references/openspec/test/commands/spec.interactive-validate.test.ts +44 -0
  288. package/references/openspec/test/commands/spec.test.ts +324 -0
  289. package/references/openspec/test/commands/validate.enriched-output.test.ts +49 -0
  290. package/references/openspec/test/commands/validate.test.ts +133 -0
  291. package/references/openspec/test/core/archive.test.ts +680 -0
  292. package/references/openspec/test/core/commands/change-command.list.test.ts +76 -0
  293. package/references/openspec/test/core/commands/change-command.show-validate.test.ts +111 -0
  294. package/references/openspec/test/core/converters/json-converter.test.ts +184 -0
  295. package/references/openspec/test/core/init.test.ts +1710 -0
  296. package/references/openspec/test/core/list.test.ts +165 -0
  297. package/references/openspec/test/core/parsers/change-parser.test.ts +52 -0
  298. package/references/openspec/test/core/parsers/markdown-parser.test.ts +291 -0
  299. package/references/openspec/test/core/update.test.ts +1642 -0
  300. package/references/openspec/test/core/validation.enriched-messages.test.ts +74 -0
  301. package/references/openspec/test/core/validation.test.ts +489 -0
  302. package/references/openspec/test/core/view.test.ts +79 -0
  303. package/references/openspec/test/fixtures/tmp-init/openspec/changes/c1/proposal.md +7 -0
  304. package/references/openspec/test/fixtures/tmp-init/openspec/changes/c1/specs/alpha/spec.md +8 -0
  305. package/references/openspec/test/fixtures/tmp-init/openspec/specs/alpha/spec.md +12 -0
  306. package/references/openspec/test/helpers/run-cli.ts +139 -0
  307. package/references/openspec/test/utils/file-system.test.ts +211 -0
  308. package/references/openspec/test/utils/marker-updates.test.ts +287 -0
  309. package/references/openspec/tsconfig.json +21 -0
  310. package/references/openspec/vitest.config.ts +25 -0
  311. package/references/openspec/vitest.setup.ts +6 -0
@@ -0,0 +1,49 @@
1
+ ## Why
2
+ Today’s process requires maintainers to merge the Changesets PR, cut a tag, and draft the GitHub release by hand. npm publish then runs from our existing workflow after the GitHub release is published. The human-in-the-loop steps (versioning, tagging, release notes) slow us down and risk drift between npm, tags, and changelog.
3
+
4
+ ## What Changes
5
+ - Use the single `changesets/action` on pushes to `main` to either open/update the version PR or, when the release PR is merged, run our publish command automatically using repository secrets.
6
+ - Add a `release` script that builds and runs `changeset publish` so the action handles version bumps, changelog commits, npm publish, and GitHub releases end-to-end.
7
+ - Enable `createGithubReleases: true` so GitHub releases are created from the changeset data right after publishing.
8
+ - Document the automated flow, required secrets, guardrails, and recovery steps (rollback, hotfixes).
9
+
10
+ ## Two-Phase Rollout (Two PRs)
11
+ 1) Phase 1 — Dry run (no publish)
12
+ - Update the existing `release-prepare.yml` to wire up `changesets/action` with `createGithubReleases: true` and a no-op `publish` command (e.g., `echo 'dry run'`).
13
+ - Keep `.github/workflows/release-publish.yml` intact. This avoids any publish path changes while we verify that the version PR behavior and permissions are correct.
14
+ - Add a repository guard (`if: github.repository == 'Fission-AI/OpenSpec'`) and a concurrency group for safety.
15
+
16
+ 2) Phase 2 — Enable publish and consolidate
17
+ - Add `"release": "pnpm run build && pnpm exec changeset publish"` to `package.json`.
18
+ - Change `release-prepare.yml` to use `with: publish: pnpm run release` and `env: NPM_TOKEN: \\${{ secrets.NPM_TOKEN }}` plus the default `GITHUB_TOKEN`.
19
+ - Remove `.github/workflows/release-publish.yml` to avoid double-publish. Publishing now happens when the version PR is merged.
20
+
21
+ ## Guardrails
22
+ - Concurrency: `concurrency: { group: release-\\${{ github.ref }}, cancel-in-progress: false }` on the workflow to serialize releases.
23
+ - Repository/branch guard: run publish logic only on upstream `main` (`if: github.repository == 'Fission-AI/OpenSpec' && github.ref == 'refs/heads/main'`).
24
+ - Permissions: ensure `contents: write` and `pull-requests: write` for opening/updating the version PR; `packages: read` optional.
25
+
26
+ ## Rollback and Hotfixes
27
+ - Rollback: revert the release PR merge (which reverts version bumps/changelog); if a tag or GitHub release was created, delete the tag and release; deprecate the npm version if necessary (`npm deprecate @fission-ai/openspec@x.y.z 'reason'`).
28
+ - Hotfix (urgent, no pending changesets): create a changeset for the fix and merge the release PR; in emergencies, run a manual bump/publish but reconcile with Changesets by adding a follow-up changeset to align versions.
29
+
30
+ ## Required Secrets
31
+ - `NPM_TOKEN` with publish rights for the `@fission-ai` scope.
32
+ - Default `GITHUB_TOKEN` (provided by GitHub) for opening/updating the version PR and creating GitHub releases.
33
+
34
+ ## How the Maintainer Flow Changes
35
+ | Step | Current process | Future process |
36
+ | --- | --- | --- |
37
+ | Prepare release | Merge changeset PR, then manually draft release notes and tags | Merge release PR; action updates versions and handles changelog automatically |
38
+ | Publish npm package | Happens automatically after GitHub release | Happens automatically via `changeset publish` invoked by the action |
39
+ | GitHub release | Draft manually and sync with changelog | Action creates GitHub releases from changeset data |
40
+ | Docs/process | Follow manual tagging/release steps | Docs describe automated flow + recovery and hotfix paths |
41
+
42
+ ## Impact
43
+ - Automation: reuse `.github/workflows/release-prepare.yml` (phase 1: dry-run, phase 2: publish) and remove `.github/workflows/release-publish.yml` in phase 2.
44
+ - Package metadata: add `release` script to `package.json`.
45
+ - Docs: update README or `/docs` to show the automated flow, secrets, guardrails, and recovery steps.
46
+
47
+ ## Acceptance Criteria
48
+ - Phase 1: merges to `main` open/update a version PR; on merge, the action’s `publish` step is a no-op; no npm publish occurs; logs confirm intended behavior; GitHub releases creation is wired but inert due to no publish.
49
+ - Phase 2: merges to `main` run `pnpm run release` from the action; npm package publishes successfully; GitHub release is created automatically; `.github/workflows/release-publish.yml` is removed; no duplicate publishes occur.
@@ -0,0 +1,12 @@
1
+ ## 1. Release workflow automation
2
+ - [x] 1.1 Add a `.github/workflows/release.yml` that runs on pushes to `main`, sets up pnpm + Node 20, installs dependencies, and invokes `changesets/action@v1` with `publish: pnpm run release`.
3
+ - [x] 1.2 Configure the action with `createGithubReleases: true` and document required secrets (`NPM_TOKEN`, default `GITHUB_TOKEN`) plus recommended concurrency safeguards.
4
+ - [x] 1.3 Validate the workflow using `act` or a dry-run push to confirm the action opens release PRs when changesets exist and publishes when the release PR merge lands.
5
+
6
+ ## 2. Package release script
7
+ - [x] 2.1 Add a `release` script to `package.json` that builds the project and runs `changeset publish` using pnpm.
8
+ - [x] 2.2 Ensure the script respects the existing `prepare`/`prepublishOnly` hooks to avoid duplicate builds and update documentation or scripts if adjustments are needed.
9
+
10
+ ## 3. Documentation and recovery steps
11
+ - [x] 3.1 Update maintainer docs (e.g., README or `/docs`) with the end-to-end automated release flow, explicitly removing the manual tag/release steps that are no longer required and explaining how changesets drive the release PR.
12
+ - [x] 3.2 Document fallback steps for failed publishes (rerun workflow, manual publish) and the hotfix path when a release must be cut without pending changesets.
@@ -0,0 +1,17 @@
1
+ # Add Archive Command Arguments
2
+
3
+ ## Why
4
+ The `/openspec:archive` slash command currently lacks argument support, forcing the AI to infer which change to archive from conversation context or by listing all changes. This creates a safety risk where the wrong proposal could be archived if the context is ambiguous or multiple changes exist. Users expect to specify the change ID explicitly, matching the behavior of the CLI command `openspec archive <id>`.
5
+
6
+ ## What Changes
7
+ - Add `$ARGUMENTS` placeholder to the OpenCode archive slash command frontmatter (matching existing pattern for proposal command)
8
+ - Update archive command template steps to validate the specific change ID argument when provided
9
+ - Note: Codex, GitHub Copilot, and Amazon Q already have `$ARGUMENTS` for archive; Claude/Cursor/Windsurf/Kilocode don't support arguments
10
+
11
+ ## Impact
12
+ - Affected specs: `cli-update` (slash command generation logic)
13
+ - Affected code:
14
+ - `src/core/configurators/slash/opencode.ts` (add `$ARGUMENTS` to archive frontmatter)
15
+ - `src/core/templates/slash-command-templates.ts` (archive template steps for argument validation)
16
+ - Breaking: No - this is additive functionality that makes the command safer
17
+ - User-facing: Yes - OpenCode users will be able to pass the change ID as an argument: `/openspec:archive <change-id>`
@@ -0,0 +1,32 @@
1
+ # CLI Update Specification Delta
2
+
3
+ ## MODIFIED Requirements
4
+
5
+ ### Requirement: Slash Command Updates
6
+ The update command SHALL refresh existing slash command files for configured tools without creating new ones, and ensure the OpenCode archive command accepts change ID arguments.
7
+
8
+ #### Scenario: Updating slash commands for OpenCode
9
+ - **WHEN** `.opencode/command/` contains `openspec-proposal.md`, `openspec-apply.md`, and `openspec-archive.md`
10
+ - **THEN** refresh each file using shared templates
11
+ - **AND** ensure templates include instructions for the relevant workflow stage
12
+ - **AND** ensure the archive command includes `$ARGUMENTS` placeholder in frontmatter for accepting change ID arguments
13
+
14
+ ### Requirement: Archive Command Argument Support
15
+ The archive slash command template SHALL support optional change ID arguments for tools that support `$ARGUMENTS` placeholder.
16
+
17
+ #### Scenario: Archive command with change ID argument
18
+ - **WHEN** a user invokes `/openspec:archive <change-id>` with a change ID
19
+ - **THEN** the template SHALL instruct the AI to validate the provided change ID against `openspec list`
20
+ - **AND** use the provided change ID for archiving if valid
21
+ - **AND** fail fast if the provided change ID doesn't match an archivable change
22
+
23
+ #### Scenario: Archive command without argument (backward compatibility)
24
+ - **WHEN** a user invokes `/openspec:archive` without providing a change ID
25
+ - **THEN** the template SHALL instruct the AI to identify the change ID from context or by running `openspec list`
26
+ - **AND** proceed with the existing behavior (maintaining backward compatibility)
27
+
28
+ #### Scenario: OpenCode archive template generation
29
+ - **WHEN** generating the OpenCode archive slash command file
30
+ - **THEN** include the `$ARGUMENTS` placeholder in the frontmatter
31
+ - **AND** wrap it in a clear structure like `<ChangeId>\n $ARGUMENTS\n</ChangeId>` to indicate the expected argument
32
+ - **AND** include validation steps in the template body to check if the change ID is valid
@@ -0,0 +1,15 @@
1
+ # Implementation Tasks
2
+
3
+ ## 1. Update OpenCode Configurator
4
+ - [x] 1.1 Add `$ARGUMENTS` placeholder to OpenCode archive frontmatter (matching the proposal pattern)
5
+ - [x] 1.2 Format it as `<ChangeId>\n $ARGUMENTS\n</ChangeId>` or similar structure for clarity
6
+ - [x] 1.3 Ensure `updateExisting` rewrites the archive frontmatter/body so `$ARGUMENTS` persists after `openspec update`
7
+
8
+ ## 2. Update Slash Command Templates
9
+ - [x] 2.1 Modify archive steps to validate change ID argument when provided via `$ARGUMENTS`
10
+ - [x] 2.2 Keep backward compatibility - allow inferring from context if no argument provided
11
+ - [x] 2.3 Add step to validate the change ID exists using `openspec list` before archiving
12
+
13
+ ## 3. Update Documentation
14
+ - [x] 3.1 Update AGENTS.md archive examples to show argument usage
15
+ - [x] 3.2 Document that OpenCode now supports `/openspec:archive <change-id>`
@@ -0,0 +1,15 @@
1
+ ## Why
2
+ Add support for Cline (VS Code extension) in OpenSpec to enable developers to use Cline's AI-powered coding capabilities for spec-driven development workflows.
3
+
4
+ ## What Changes
5
+ - Add Cline slash command configurator for proposal, apply, and archive operations
6
+ - Add Cline root CLINE.md configurator for project-level instructions
7
+ - Add Cline template exports
8
+ - Update tool and slash command registries to include Cline
9
+ - Add comprehensive test coverage
10
+ - **BREAKING**: None - this is additive functionality
11
+
12
+ ## Impact
13
+ - Affected specs: cli-init (new tool option)
14
+ - Affected code: src/core/configurators/slash/cline.ts, src/core/configurators/cline.ts, registry files
15
+ - New files: .clinerules/openspec-*.md, CLINE.md
@@ -0,0 +1,97 @@
1
+ ## MODIFIED Requirements
2
+ ### Requirement: AI Tool Configuration Details
3
+
4
+ The command SHALL properly configure selected AI tools with OpenSpec-specific instructions using a marker system.
5
+
6
+ #### Scenario: Configuring Claude Code
7
+
8
+ - **WHEN** Claude Code is selected
9
+ - **THEN** create or update `CLAUDE.md` in the project root directory (not inside openspec/)
10
+ - **AND** populate the managed block with a short stub that points teammates to `@/openspec/AGENTS.md`
11
+
12
+ #### Scenario: Configuring CodeBuddy Code
13
+
14
+ - **WHEN** CodeBuddy Code is selected
15
+ - **THEN** create or update `CODEBUDDY.md` in the project root directory (not inside openspec/)
16
+ - **AND** populate the managed block with a short stub that points teammates to `@/openspec/AGENTS.md`
17
+
18
+ #### Scenario: Configuring Cline
19
+
20
+ - **WHEN** Cline is selected
21
+ - **THEN** create or update `CLINE.md` in the project root directory (not inside openspec/)
22
+ - **AND** populate the managed block with a short stub that points teammates to `@/openspec/AGENTS.md`
23
+
24
+ #### Scenario: Creating new CLAUDE.md
25
+
26
+ - **WHEN** CLAUDE.md does not exist
27
+ - **THEN** create new file with stub instructions wrapped in markers so the full workflow stays in `openspec/AGENTS.md`:
28
+ ```markdown
29
+ <!-- OPENSPEC:START -->
30
+ # OpenSpec Instructions
31
+
32
+ This project uses OpenSpec to manage AI assistant workflows.
33
+
34
+ - Full guidance lives in '@/openspec/AGENTS.md'.
35
+ - Keep this managed block so 'openspec update' can refresh the instructions.
36
+ <!-- OPENSPEC:END -->
37
+ ```
38
+
39
+ ### Requirement: Slash Command Configuration
40
+ The init command SHALL generate slash command files for supported editors using shared templates.
41
+
42
+ #### Scenario: Generating slash commands for Claude Code
43
+ - **WHEN** the user selects Claude Code during initialization
44
+ - **THEN** create `.claude/commands/openspec/proposal.md`, `.claude/commands/openspec/apply.md`, and `.claude/commands/openspec/archive.md`
45
+ - **AND** populate each file from shared templates so command text matches other tools
46
+ - **AND** each template includes instructions for the relevant OpenSpec workflow stage
47
+
48
+ #### Scenario: Generating slash commands for CodeBuddy Code
49
+ - **WHEN** the user selects CodeBuddy Code during initialization
50
+ - **THEN** create `.codebuddy/commands/openspec/proposal.md`, `.codebuddy/commands/openspec/apply.md`, and `.codebuddy/commands/openspec/archive.md`
51
+ - **AND** populate each file from shared templates so command text matches other tools
52
+ - **AND** each template includes instructions for the relevant OpenSpec workflow stage
53
+
54
+ #### Scenario: Generating slash commands for Cline
55
+ - **WHEN** the user selects Cline during initialization
56
+ - **THEN** create `.clinerules/openspec-proposal.md`, `.clinerules/openspec-apply.md`, and `.clinerules/openspec-archive.md`
57
+ - **AND** populate each file from shared templates so command text matches other tools
58
+ - **AND** include Cline-specific Markdown heading frontmatter
59
+ - **AND** each template includes instructions for the relevant OpenSpec workflow stage
60
+
61
+ #### Scenario: Generating slash commands for Cursor
62
+ - **WHEN** the user selects Cursor during initialization
63
+ - **THEN** create `.cursor/commands/openspec-proposal.md`, `.cursor/commands/openspec-apply.md`, and `.cursor/commands/openspec-archive.md`
64
+ - **AND** populate each file from shared templates so command text matches other tools
65
+ - **AND** each template includes instructions for the relevant OpenSpec workflow stage
66
+
67
+ #### Scenario: Generating slash commands for OpenCode
68
+ - **WHEN** the user selects OpenCode during initialization
69
+ - **THEN** create `.opencode/commands/openspec-proposal.md`, `.opencode/commands/openspec-apply.md`, and `.opencode/commands/openspec-archive.md`
70
+ - **AND** populate each file from shared templates so command text matches other tools
71
+ - **AND** each template includes instructions for the relevant OpenSpec workflow stage
72
+
73
+ #### Scenario: Generating slash commands for Windsurf
74
+ - **WHEN** the user selects Windsurf during initialization
75
+ - **THEN** create `.windsurf/workflows/openspec-proposal.md`, `.windsurf/workflows/openspec-apply.md`, and `.windsurf/workflows/openspec-archive.md`
76
+ - **AND** populate each file from shared templates (wrapped in OpenSpec markers) so workflow text matches other tools
77
+ - **AND** each template includes instructions for the relevant OpenSpec workflow stage
78
+
79
+ #### Scenario: Generating slash commands for Kilo Code
80
+ - **WHEN** the user selects Kilo Code during initialization
81
+ - **THEN** create `.kilocode/workflows/openspec-proposal.md`, `.kilocode/workflows/openspec-apply.md`, and `.kilocode/workflows/openspec-archive.md`
82
+ - **AND** populate each file from shared templates (wrapped in OpenSpec markers) so workflow text matches other tools
83
+ - **AND** each template includes instructions for the relevant OpenSpec workflow stage
84
+
85
+ #### Scenario: Generating slash commands for Codex
86
+ - **WHEN** the user selects Codex during initialization
87
+ - **THEN** create global prompt files at `~/.codex/prompts/openspec-proposal.md`, `~/.codex/prompts/openspec-apply.md`, and `~/.codex/prompts/openspec-archive.md` (or under `$CODEX_HOME/prompts` if set)
88
+ - **AND** populate each file from shared templates that map the first numbered placeholder (`$1`) to the primary user input (e.g., change identifier or question text)
89
+ - **AND** wrap the generated content in OpenSpec markers so `openspec update` can refresh the prompts without touching surrounding custom notes
90
+
91
+ #### Scenario: Generating slash commands for GitHub Copilot
92
+ - **WHEN** the user selects GitHub Copilot during initialization
93
+ - **THEN** create `.github/prompts/openspec-proposal.prompt.md`, `.github/prompts/openspec-apply.prompt.md`, and `.github/prompts/openspec-archive.prompt.md`
94
+ - **AND** populate each file with YAML frontmatter containing a `description` field that summarizes the workflow stage
95
+ - **AND** include `$ARGUMENTS` placeholder to capture user input
96
+ - **AND** wrap the shared template body with OpenSpec markers so `openspec update` can refresh the content
97
+ - **AND** each template includes instructions for the relevant OpenSpec workflow stage
@@ -0,0 +1,19 @@
1
+ ## 1. Implementation
2
+ - [x] 1.1 Create ClineSlashCommandConfigurator class in src/core/configurators/slash/cline.ts
3
+ - [x] 1.2 Create ClineConfigurator class in src/core/configurators/cline.ts
4
+ - [x] 1.3 Create cline-template.ts for template exports
5
+ - [x] 1.4 Define file paths for Cline rules (.clinerules/)
6
+ - [x] 1.5 Create Cline-specific frontmatter (Markdown heading format)
7
+ - [x] 1.6 Register Cline in slash/registry.ts
8
+ - [x] 1.7 Register Cline in configurators/registry.ts
9
+ - [x] 1.8 Add Cline to AI_TOOLS in config.ts
10
+ - [x] 1.9 Add getClineTemplate() to templates/index.ts
11
+ - [x] 1.10 Update README with Cline documentation
12
+
13
+ ## 2. Testing
14
+ - [x] 2.1 Add init tests for CLINE.md creation and updates
15
+ - [x] 2.2 Add init tests for .clinerules/ file creation
16
+ - [x] 2.3 Add update tests for CLINE.md updates
17
+ - [x] 2.4 Add update tests for .clinerules/ file refreshes
18
+ - [x] 2.5 Test integration with openspec init --tools cline
19
+ - [x] 2.6 Verify all 225 tests pass
@@ -0,0 +1,13 @@
1
+ ## Why
2
+ Add support for Crush AI assistant in OpenSpec to enable developers to use Crush's enhanced capabilities for spec-driven development workflows.
3
+
4
+ ## What Changes
5
+ - Add Crush slash command configurator for proposal, apply, and archive operations
6
+ - Add Crush-specific AGENTS.md configuration template
7
+ - Update tool registry to include Crush configurator
8
+ - **BREAKING**: None - this is additive functionality
9
+
10
+ ## Impact
11
+ - Affected specs: cli-init (new tool option)
12
+ - Affected code: src/core/configurators/slash/crush.ts, registry.ts
13
+ - New files: .crush/commands/openspec/ (proposal.md, apply.md, archive.md)
@@ -0,0 +1,67 @@
1
+ ## MODIFIED Requirements
2
+ ### Requirement: Slash Command Configuration
3
+ The init command SHALL generate slash command files for supported editors using shared templates.
4
+
5
+ #### Scenario: Generating slash commands for Claude Code
6
+ - **WHEN** the user selects Claude Code during initialization
7
+ - **THEN** create `.claude/commands/openspec/proposal.md`, `.claude/commands/openspec/apply.md`, and `.claude/commands/openspec/archive.md`
8
+ - **AND** populate each file from shared templates so command text matches other tools
9
+ - **AND** each template includes instructions for the relevant OpenSpec workflow stage
10
+
11
+ #### Scenario: Generating slash commands for CodeBuddy Code
12
+ - **WHEN** the user selects CodeBuddy Code during initialization
13
+ - **THEN** create `.codebuddy/commands/openspec/proposal.md`, `.codebuddy/commands/openspec/apply.md`, and `.codebuddy/commands/openspec/archive.md`
14
+ - **AND** populate each file from shared templates so command text matches other tools
15
+ - **AND** each template includes instructions for the relevant OpenSpec workflow stage
16
+
17
+ #### Scenario: Generating slash commands for Cline
18
+ - **WHEN** the user selects Cline during initialization
19
+ - **THEN** create `.clinerules/openspec-proposal.md`, `.clinerules/openspec-apply.md`, and `.clinerules/openspec-archive.md`
20
+ - **AND** populate each file from shared templates so command text matches other tools
21
+ - **AND** include Cline-specific Markdown heading frontmatter
22
+ - **AND** each template includes instructions for the relevant OpenSpec workflow stage
23
+
24
+ #### Scenario: Generating slash commands for Crush
25
+ - **WHEN** the user selects Crush during initialization
26
+ - **THEN** create `.crush/commands/openspec/proposal.md`, `.crush/commands/openspec/apply.md`, and `.crush/commands/openspec/archive.md`
27
+ - **AND** populate each file from shared templates so command text matches other tools
28
+ - **AND** include Crush-specific frontmatter with OpenSpec category and tags
29
+ - **AND** each template includes instructions for the relevant OpenSpec workflow stage
30
+
31
+ #### Scenario: Generating slash commands for Cursor
32
+ - **WHEN** the user selects Cursor during initialization
33
+ - **THEN** create `.cursor/commands/openspec-proposal.md`, `.cursor/commands/openspec-apply.md`, and `.cursor/commands/openspec-archive.md`
34
+ - **AND** populate each file from shared templates so command text matches other tools
35
+ - **AND** each template includes instructions for the relevant OpenSpec workflow stage
36
+
37
+ #### Scenario: Generating slash commands for OpenCode
38
+ - **WHEN** the user selects OpenCode during initialization
39
+ - **THEN** create `.opencode/commands/openspec-proposal.md`, `.opencode/commands/openspec-apply.md`, and `.opencode/commands/openspec-archive.md`
40
+ - **AND** populate each file from shared templates so command text matches other tools
41
+ - **AND** each template includes instructions for the relevant OpenSpec workflow stage
42
+
43
+ #### Scenario: Generating slash commands for Windsurf
44
+ - **WHEN** the user selects Windsurf during initialization
45
+ - **THEN** create `.windsurf/workflows/openspec-proposal.md`, `.windsurf/workflows/openspec-apply.md`, and `.windsurf/workflows/openspec-archive.md`
46
+ - **AND** populate each file from shared templates (wrapped in OpenSpec markers) so workflow text matches other tools
47
+ - **AND** each template includes instructions for the relevant OpenSpec workflow stage
48
+
49
+ #### Scenario: Generating slash commands for Kilo Code
50
+ - **WHEN** the user selects Kilo Code during initialization
51
+ - **THEN** create `.kilocode/workflows/openspec-proposal.md`, `.kilocode/workflows/openspec-apply.md`, and `.kilocode/workflows/openspec-archive.md`
52
+ - **AND** populate each file from shared templates (wrapped in OpenSpec markers) so workflow text matches other tools
53
+ - **AND** each template includes instructions for the relevant OpenSpec workflow stage
54
+
55
+ #### Scenario: Generating slash commands for Codex
56
+ - **WHEN** the user selects Codex during initialization
57
+ - **THEN** create global prompt files at `~/.codex/prompts/openspec-proposal.md`, `~/.codex/prompts/openspec-apply.md`, and `~/.codex/prompts/openspec-archive.md` (or under `$CODEX_HOME/prompts` if set)
58
+ - **AND** populate each file from shared templates that map the first numbered placeholder (`$1`) to the primary user input (e.g., change identifier or question text)
59
+ - **AND** wrap the generated content in OpenSpec markers so `openspec update` can refresh the prompts without touching surrounding custom notes
60
+
61
+ #### Scenario: Generating slash commands for GitHub Copilot
62
+ - **WHEN** the user selects GitHub Copilot during initialization
63
+ - **THEN** create `.github/prompts/openspec-proposal.prompt.md`, `.github/prompts/openspec-apply.prompt.md`, and `.github/prompts/openspec-archive.prompt.md`
64
+ - **AND** populate each file with YAML frontmatter containing a `description` field that summarizes the workflow stage
65
+ - **AND** include `$ARGUMENTS` placeholder to capture user input
66
+ - **AND** wrap the shared template body with OpenSpec markers so `openspec update` can refresh the content
67
+ - **AND** each template includes instructions for the relevant OpenSpec workflow stage
@@ -0,0 +1,7 @@
1
+ ## 1. Implementation
2
+ - [x] 1.1 Create CrushSlashCommandConfigurator class in src/core/configurators/slash/crush.ts
3
+ - [x] 1.2 Define file paths for Crush commands (.crush/commands/openspec/)
4
+ - [x] 1.3 Create Crush-specific frontmatter for proposal, apply, archive commands
5
+ - [x] 1.4 Register Crush configurator in slash/registry.ts
6
+ - [x] 1.5 Add Crush to available tools in cli-init command
7
+ - [x] 1.6 Test integration with openspec init --tool crush
@@ -0,0 +1,12 @@
1
+ ## Why
2
+ Factory's Droid CLI recently shipped custom slash commands that mirror other native assistant integrations. Teams using OpenSpec want the same managed workflows they already get for Cursor, Windsurf, and others so init/update can provision and refresh Factory commands without manual setup.
3
+
4
+ ## What Changes
5
+ - Extend the native tool registry so Factory/Droid appears alongside other slash-command integrations during `openspec init`.
6
+ - Add shared templates that generate the three Factory custom commands (proposal, apply, archive) and wrap them in OpenSpec markers for safe refreshes.
7
+ - Update the init and update command flows so they create or refresh Factory command files when the tool is selected or already present.
8
+ - Refresh CLI specs to document the Factory support and align validation expectations.
9
+
10
+ ## Impact
11
+ - Affected specs: `specs/cli-init`, `specs/cli-update`
12
+ - Affected code (expected): tool registry, slash-command template manager, init/update command helpers, documentation snippets
@@ -0,0 +1,54 @@
1
+ ## MODIFIED Requirements
2
+ ### Requirement: Slash Command Configuration
3
+ The init command SHALL generate slash command files for supported editors using shared templates.
4
+
5
+ #### Scenario: Generating slash commands for Claude Code
6
+ - **WHEN** the user selects Claude Code during initialization
7
+ - **THEN** create `.claude/commands/openspec/proposal.md`, `.claude/commands/openspec/apply.md`, and `.claude/commands/openspec/archive.md`
8
+ - **AND** populate each file from shared templates so command text matches other tools
9
+ - **AND** each template includes instructions for the relevant OpenSpec workflow stage
10
+
11
+ #### Scenario: Generating slash commands for Cursor
12
+ - **WHEN** the user selects Cursor during initialization
13
+ - **THEN** create `.cursor/commands/openspec-proposal.md`, `.cursor/commands/openspec-apply.md`, and `.cursor/commands/openspec-archive.md`
14
+ - **AND** populate each file from shared templates so command text matches other tools
15
+ - **AND** each template includes instructions for the relevant OpenSpec workflow stage
16
+
17
+ #### Scenario: Generating slash commands for Factory Droid
18
+ - **WHEN** the user selects Factory Droid during initialization
19
+ - **THEN** create `.factory/commands/openspec-proposal.md`, `.factory/commands/openspec-apply.md`, and `.factory/commands/openspec-archive.md`
20
+ - **AND** populate each file from shared templates that include Factory-compatible YAML frontmatter for the `description` and `argument-hint` fields
21
+ - **AND** include the `$ARGUMENTS` placeholder in the template body so droid receives any user-supplied input
22
+ - **AND** wrap the generated content in OpenSpec managed markers so `openspec update` can safely refresh the commands
23
+
24
+ #### Scenario: Generating slash commands for OpenCode
25
+ - **WHEN** the user selects OpenCode during initialization
26
+ - **THEN** create `.opencode/commands/openspec-proposal.md`, `.opencode/commands/openspec-apply.md`, and `.opencode/commands/openspec-archive.md`
27
+ - **AND** populate each file from shared templates so command text matches other tools
28
+ - **AND** each template includes instructions for the relevant OpenSpec workflow stage
29
+
30
+ #### Scenario: Generating slash commands for Windsurf
31
+ - **WHEN** the user selects Windsurf during initialization
32
+ - **THEN** create `.windsurf/workflows/openspec-proposal.md`, `.windsurf/workflows/openspec-apply.md`, and `.windsurf/workflows/openspec-archive.md`
33
+ - **AND** populate each file from shared templates (wrapped in OpenSpec markers) so workflow text matches other tools
34
+ - **AND** each template includes instructions for the relevant OpenSpec workflow stage
35
+
36
+ #### Scenario: Generating slash commands for Kilo Code
37
+ - **WHEN** the user selects Kilo Code during initialization
38
+ - **THEN** create `.kilocode/workflows/openspec-proposal.md`, `.kilocode/workflows/openspec-apply.md`, and `.kilocode/workflows/openspec-archive.md`
39
+ - **AND** populate each file from shared templates (wrapped in OpenSpec markers) so workflow text matches other tools
40
+ - **AND** each template includes instructions for the relevant OpenSpec workflow stage
41
+
42
+ #### Scenario: Generating slash commands for Codex
43
+ - **WHEN** the user selects Codex during initialization
44
+ - **THEN** create global prompt files at `~/.codex/prompts/openspec-proposal.md`, `~/.codex/prompts/openspec-apply.md`, and `~/.codex/prompts/openspec-archive.md` (or under `$CODEX_HOME/prompts` if set)
45
+ - **AND** populate each file from shared templates that map the first numbered placeholder (`$1`) to the primary user input (e.g., change identifier or question text)
46
+ - **AND** wrap the generated content in OpenSpec markers so `openspec update` can refresh the prompts without touching surrounding custom notes
47
+
48
+ #### Scenario: Generating slash commands for GitHub Copilot
49
+ - **WHEN** the user selects GitHub Copilot during initialization
50
+ - **THEN** create `.github/prompts/openspec-proposal.prompt.md`, `.github/prompts/openspec-apply.prompt.md`, and `.github/prompts/openspec-archive.prompt.md`
51
+ - **AND** populate each file with YAML frontmatter containing a `description` field that summarizes the workflow stage
52
+ - **AND** include `$ARGUMENTS` placeholder to capture user input
53
+ - **AND** wrap the shared template body with OpenSpec markers so `openspec update` can refresh the content
54
+ - **AND** each template includes instructions for the relevant OpenSpec workflow stage
@@ -0,0 +1,54 @@
1
+ ## MODIFIED Requirements
2
+ ### Requirement: Slash Command Updates
3
+ The update command SHALL refresh existing slash command files for configured tools without creating new ones.
4
+
5
+ #### Scenario: Updating slash commands for Claude Code
6
+ - **WHEN** `.claude/commands/openspec/` contains `proposal.md`, `apply.md`, and `archive.md`
7
+ - **THEN** refresh each file using shared templates
8
+ - **AND** ensure templates include instructions for the relevant workflow stage
9
+
10
+ #### Scenario: Updating slash commands for Cursor
11
+ - **WHEN** `.cursor/commands/` contains `openspec-proposal.md`, `openspec-apply.md`, and `openspec-archive.md`
12
+ - **THEN** refresh each file using shared templates
13
+ - **AND** ensure templates include instructions for the relevant workflow stage
14
+
15
+ #### Scenario: Updating slash commands for Factory Droid
16
+ - **WHEN** `.factory/commands/` contains `openspec-proposal.md`, `openspec-apply.md`, and `openspec-archive.md`
17
+ - **THEN** refresh each file using the shared Factory templates that include YAML frontmatter for the `description` and `argument-hint` fields
18
+ - **AND** ensure the template body retains the `$ARGUMENTS` placeholder so user input keeps flowing into droid
19
+ - **AND** update only the content inside the OpenSpec managed markers, leaving any unmanaged notes untouched
20
+ - **AND** skip creating missing files during update
21
+
22
+ #### Scenario: Updating slash commands for OpenCode
23
+ - **WHEN** `.opencode/command/` contains `openspec-proposal.md`, `openspec-apply.md`, and `openspec-archive.md`
24
+ - **THEN** refresh each file using shared templates
25
+ - **AND** ensure templates include instructions for the relevant workflow stage
26
+
27
+ #### Scenario: Updating slash commands for Windsurf
28
+ - **WHEN** `.windsurf/workflows/` contains `openspec-proposal.md`, `openspec-apply.md`, and `openspec-archive.md`
29
+ - **THEN** refresh each file using shared templates wrapped in OpenSpec markers
30
+ - **AND** ensure templates include instructions for the relevant workflow stage
31
+ - **AND** skip creating missing files (the update command only refreshes what already exists)
32
+
33
+ #### Scenario: Updating slash commands for Kilo Code
34
+ - **WHEN** `.kilocode/workflows/` contains `openspec-proposal.md`, `openspec-apply.md`, and `openspec-archive.md`
35
+ - **THEN** refresh each file using shared templates wrapped in OpenSpec markers
36
+ - **AND** ensure templates include instructions for the relevant workflow stage
37
+ - **AND** skip creating missing files (the update command only refreshes what already exists)
38
+
39
+ #### Scenario: Updating slash commands for Codex
40
+ - **GIVEN** the global Codex prompt directory contains `openspec-proposal.md`, `openspec-apply.md`, and `openspec-archive.md`
41
+ - **WHEN** a user runs `openspec update`
42
+ - **THEN** refresh each file using the shared slash-command templates (including placeholder guidance)
43
+ - **AND** preserve any unmanaged content outside the OpenSpec marker block
44
+ - **AND** skip creation when a Codex prompt file is missing
45
+
46
+ #### Scenario: Updating slash commands for GitHub Copilot
47
+ - **WHEN** `.github/prompts/` contains `openspec-proposal.prompt.md`, `openspec-apply.prompt.md`, and `openspec-archive.prompt.md`
48
+ - **THEN** refresh each file using shared templates while preserving the YAML frontmatter
49
+ - **AND** update only the OpenSpec-managed block between markers
50
+ - **AND** ensure templates include instructions for the relevant workflow stage
51
+
52
+ #### Scenario: Missing slash command file
53
+ - **WHEN** a tool lacks a slash command file
54
+ - **THEN** do not create a new file during update
@@ -0,0 +1,11 @@
1
+ ## 1. Factory tool registration
2
+ - [x] 1.1 Add Factory/Droid metadata to the native tool registry used by init/update (ID, display name, command paths, availability flags).
3
+ - [x] 1.2 Surface Factory in interactive prompts and non-interactive `--tools` parsing alongside existing slash-command integrations.
4
+
5
+ ## 2. Slash command templates
6
+ - [x] 2.1 Create shared templates for Factory's `openspec-proposal`, `openspec-apply`, and `openspec-archive` custom commands following Factory's CLI format.
7
+ - [x] 2.2 Wire the templates into init/update so generation happens on create and refresh respects OpenSpec markers.
8
+
9
+ ## 3. Verification
10
+ - [x] 3.1 Update or add automated coverage that ensures Factory command files are scaffolded and refreshed correctly.
11
+ - [x] 3.2 Document the new option in any user-facing copy (help text, README snippets) if required by spec.
@@ -0,0 +1,13 @@
1
+ ## Why
2
+ The Cline implementation was architecturally incorrect. According to Cline's official documentation, Cline uses workflows for on-demand automation and rules for behavioral guidelines. The OpenSpec slash commands are procedural workflows (scaffold → implement → archive), not behavioral rules, so they should be placed in `.clinerules/workflows/` instead of `.clinerules/`.
3
+
4
+ ## What Changes
5
+ - Update ClineSlashCommandConfigurator to use `.clinerules/workflows/` paths instead of `.clinerules/` paths
6
+ - Update all tests to expect the correct workflow file locations
7
+ - Update README.md documentation to reflect workflows instead of rules
8
+ - **BREAKING**: Existing Cline users will need to re-run `openspec init` to get the corrected workflow files
9
+
10
+ ## Impact
11
+ - Affected specs: cli-init (corrected Cline workflow paths)
12
+ - Affected code: `src/core/configurators/slash/cline.ts`, test files, README.md
13
+ - Modified files: `.clinerules/workflows/openspec-*.md` (moved from `.clinerules/openspec-*.md`)
@@ -0,0 +1,11 @@
1
+ # Delta for CLI Init
2
+
3
+ ## MODIFIED Requirements
4
+ ### Requirement: Slash Command Configuration
5
+
6
+ #### Scenario: Generating slash commands for Cline
7
+ - **WHEN** the user selects Cline during initialization
8
+ - **THEN** create `.clinerules/workflows/openspec-proposal.md`, `.clinerules/workflows/openspec-apply.md`, and `.clinerules/workflows/openspec-archive.md`
9
+ - **AND** populate each file from shared templates so command text matches other tools
10
+ - **AND** include Cline-specific Markdown heading frontmatter
11
+ - **AND** each template includes instructions for the relevant OpenSpec workflow stage
@@ -0,0 +1,13 @@
1
+ ## 1. Update ClineSlashCommandConfigurator
2
+ - [x] Change FILE_PATHS in `src/core/configurators/slash/cline.ts` from `.clinerules/openspec-*.md` to `.clinerules/workflows/openspec-*.md`
3
+
4
+ ## 2. Update Tests
5
+ - [x] Update "should refresh existing Cline rule files" test in `test/core/update.test.ts` to use workflow paths
6
+ - [x] Update "should create Cline rule files with templates" test in `test/core/init.test.ts` to use workflow paths
7
+
8
+ ## 3. Update Documentation
9
+ - [x] Update README.md table to show "Workflows in `.clinerules/workflows/` directory" for Cline
10
+
11
+ ## 4. Validate Changes
12
+ - [x] Ensure all tests pass with the new paths
13
+ - [x] Verify the change follows OpenSpec conventions
@@ -0,0 +1,12 @@
1
+ ## Why
2
+ Validation currently errors on changes without spec deltas, even when the change is intentionally proposal-only or tooling-only. This creates false negatives and noisy CI.
3
+
4
+ ## What Changes
5
+ - Make change validation scope-aware: validate only artifacts that exist.
6
+ - Only error on "No deltas found" if spec delta files exist but parse to zero deltas.
7
+ - Keep archive stricter: if specs exist but parse to zero deltas, fail; allow `--skip-specs` for tooling-only changes.
8
+
9
+ ## Impact
10
+ - Affected specs: cli-validate
11
+ - Affected code: `src/commands/validate.ts`, `src/core/validation/validator.ts`
12
+
@@ -0,0 +1,25 @@
1
+ ## ADDED Requirements
2
+ ### Requirement: Scope-Aware Change Validation
3
+ The validator SHALL validate only artifacts that exist for a change, avoiding errors for proposal-only or tooling-only changes.
4
+
5
+ #### Scenario: Proposal-only change
6
+ - **WHEN** a change contains `proposal.md` but has no `specs/` directory or contains no `*/spec.md` files
7
+ - **THEN** validate the proposal (Why/What sections)
8
+ - **AND** do not require or validate spec deltas
9
+
10
+ #### Scenario: Delta validation when specs exist
11
+ - **WHEN** a change contains one or more `specs/<capability>/spec.md` files
12
+ - **THEN** validate delta-formatted specs with existing rules (SHALL/MUST, scenarios, duplicates, conflicts)
13
+
14
+ ## MODIFIED Requirements
15
+ ### Requirement: Validation SHALL provide actionable remediation steps
16
+ Validation output SHALL include specific guidance to fix each error, including expected structure, example headers, and suggested commands to verify fixes.
17
+
18
+ #### Scenario: No deltas found in change
19
+ - **WHEN** validating a change that contains `specs/` with one or more `*/spec.md` files but the parser finds zero deltas
20
+ - **THEN** show error "No deltas found" with guidance:
21
+ - Ensure `openspec/changes/{id}/specs/` has `.md` files that include delta headers
22
+ - Use delta headers: `## ADDED Requirements`, `## MODIFIED Requirements`, `## REMOVED Requirements`, `## RENAMED Requirements`
23
+ - Each requirement must include at least one `#### Scenario:` block
24
+ - Try: `openspec change show {id} --json --deltas-only` to inspect parsed deltas
25
+
@@ -0,0 +1,16 @@
1
+ ## 1. Validator changes
2
+ - [ ] 1.1 Change `validateChangeDeltaSpecs` to only emit "Change must have at least one delta" when `specs/` exists and contains at least one `*/spec.md` but parsed total deltas is 0
3
+ - [ ] 1.2 Return valid (no error) when `specs/` directory is missing or has no `spec.md` files
4
+
5
+ ## 2. CLI changes
6
+ - [ ] 2.1 In bulk validation, keep current behavior (call delta validator). Behavior remains correct after 1.1
7
+ - [ ] 2.2 Add a short INFO log in human-readable mode when a change has no `specs/` (optional)
8
+
9
+ ## 3. Documentation
10
+ - [ ] 3.1 Update README and template: "Validation checks only existing artifacts. Proposal-only changes are valid without spec deltas."
11
+
12
+ ## 4. Tests
13
+ - [ ] 4.1 Add test: proposal-only change passes validation without deltas
14
+ - [ ] 4.2 Add test: specs present but zero parsed deltas → ERROR
15
+ - [ ] 4.3 Add test: specs present with proper deltas → valid
16
+