bmad-method 6.12.4 → 7.1.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 (389) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +107 -54
  3. package/agents.json +640 -0
  4. package/bin/bmad-method.js +4 -0
  5. package/messages.yaml +267 -0
  6. package/modules.yaml +56 -0
  7. package/package.json +32 -110
  8. package/src/agent-picks.js +77 -0
  9. package/src/agents.js +141 -0
  10. package/src/bmad-scripts.js +167 -0
  11. package/src/cli.js +266 -0
  12. package/src/commands/agent-choice.js +67 -0
  13. package/src/commands/apply.js +38 -0
  14. package/src/commands/deps.js +25 -0
  15. package/src/commands/ending.js +66 -0
  16. package/src/commands/existing-install.js +50 -0
  17. package/src/commands/install-plan.js +130 -0
  18. package/src/commands/install-steps.js +66 -0
  19. package/src/commands/install.js +86 -0
  20. package/src/commands/status.js +39 -0
  21. package/src/commands/update.js +106 -0
  22. package/src/installed.js +48 -0
  23. package/src/messages.js +84 -0
  24. package/src/modules.js +221 -0
  25. package/src/preflight.js +124 -0
  26. package/src/project-lock.js +68 -0
  27. package/src/prompts.js +626 -0
  28. package/src/report.js +199 -0
  29. package/src/run.js +128 -0
  30. package/src/self-update.js +88 -0
  31. package/src/skills-cli.js +133 -0
  32. package/src/version.js +11 -0
  33. package/.claude-plugin/marketplace.json +0 -53
  34. package/AGENTS.md +0 -24
  35. package/CLAUDE.md +0 -1
  36. package/README_CN.md +0 -98
  37. package/README_KR.md +0 -90
  38. package/README_VN.md +0 -99
  39. package/bmad-modules.yaml +0 -140
  40. package/body.md +0 -17
  41. package/greptile.json +0 -52
  42. package/pr2.md +0 -11
  43. package/removals.txt +0 -87
  44. package/src/bmm-skills/agents/bmad-agent-analyst/SKILL.md +0 -76
  45. package/src/bmm-skills/agents/bmad-agent-analyst/customize.toml +0 -103
  46. package/src/bmm-skills/agents/bmad-agent-architect/SKILL.md +0 -76
  47. package/src/bmm-skills/agents/bmad-agent-architect/customize.toml +0 -63
  48. package/src/bmm-skills/agents/bmad-agent-dev/SKILL.md +0 -76
  49. package/src/bmm-skills/agents/bmad-agent-dev/customize.toml +0 -81
  50. package/src/bmm-skills/agents/bmad-agent-pm/SKILL.md +0 -76
  51. package/src/bmm-skills/agents/bmad-agent-pm/customize.toml +0 -73
  52. package/src/bmm-skills/agents/bmad-agent-ux-designer/SKILL.md +0 -76
  53. package/src/bmm-skills/agents/bmad-agent-ux-designer/customize.toml +0 -58
  54. package/src/bmm-skills/module-help.csv +0 -19
  55. package/src/bmm-skills/module.yaml +0 -85
  56. package/src/bmm-skills/plan/bmad-architecture/SKILL.md +0 -85
  57. package/src/bmm-skills/plan/bmad-architecture/assets/spine-template.md +0 -79
  58. package/src/bmm-skills/plan/bmad-architecture/customize.toml +0 -101
  59. package/src/bmm-skills/plan/bmad-architecture/references/headless.md +0 -26
  60. package/src/bmm-skills/plan/bmad-architecture/references/reviewer-gate.md +0 -13
  61. package/src/bmm-skills/plan/bmad-architecture/scripts/lint_spine.py +0 -261
  62. package/src/bmm-skills/plan/bmad-architecture/scripts/tests/test_lint_spine.py +0 -270
  63. package/src/bmm-skills/plan/bmad-create-epics-and-stories/SKILL.md +0 -93
  64. package/src/bmm-skills/plan/bmad-create-epics-and-stories/customize.toml +0 -39
  65. package/src/bmm-skills/plan/bmad-create-epics-and-stories/steps/step-01-validate-prerequisites.md +0 -263
  66. package/src/bmm-skills/plan/bmad-create-epics-and-stories/steps/step-02-design-epics.md +0 -242
  67. package/src/bmm-skills/plan/bmad-create-epics-and-stories/steps/step-03-create-stories.md +0 -255
  68. package/src/bmm-skills/plan/bmad-create-epics-and-stories/steps/step-04-final-validation.md +0 -141
  69. package/src/bmm-skills/plan/bmad-create-epics-and-stories/templates/epics-template.md +0 -62
  70. package/src/bmm-skills/plan/bmad-generate-project-context/SKILL.md +0 -12
  71. package/src/bmm-skills/plan/bmad-prd/SKILL.md +0 -94
  72. package/src/bmm-skills/plan/bmad-prd/assets/headless-schemas.md +0 -76
  73. package/src/bmm-skills/plan/bmad-prd/assets/prd-template.md +0 -165
  74. package/src/bmm-skills/plan/bmad-prd/assets/prd-validation-checklist.md +0 -135
  75. package/src/bmm-skills/plan/bmad-prd/assets/validation-report-template.html +0 -325
  76. package/src/bmm-skills/plan/bmad-prd/customize.toml +0 -148
  77. package/src/bmm-skills/plan/bmad-prd/references/headless.md +0 -39
  78. package/src/bmm-skills/plan/bmad-prd/references/validate.md +0 -97
  79. package/src/bmm-skills/plan/bmad-prfaq/SKILL.md +0 -135
  80. package/src/bmm-skills/plan/bmad-prfaq/agents/artifact-analyzer.md +0 -60
  81. package/src/bmm-skills/plan/bmad-prfaq/agents/web-researcher.md +0 -49
  82. package/src/bmm-skills/plan/bmad-prfaq/assets/prfaq-template.md +0 -62
  83. package/src/bmm-skills/plan/bmad-prfaq/bmad-manifest.json +0 -16
  84. package/src/bmm-skills/plan/bmad-prfaq/customize.toml +0 -39
  85. package/src/bmm-skills/plan/bmad-prfaq/references/customer-faq.md +0 -55
  86. package/src/bmm-skills/plan/bmad-prfaq/references/internal-faq.md +0 -51
  87. package/src/bmm-skills/plan/bmad-prfaq/references/press-release.md +0 -60
  88. package/src/bmm-skills/plan/bmad-prfaq/references/verdict.md +0 -83
  89. package/src/bmm-skills/plan/bmad-product-brief/SKILL.md +0 -91
  90. package/src/bmm-skills/plan/bmad-product-brief/assets/brief-template.md +0 -41
  91. package/src/bmm-skills/plan/bmad-product-brief/customize.toml +0 -100
  92. package/src/bmm-skills/plan/bmad-project-context/SKILL.md +0 -121
  93. package/src/bmm-skills/plan/bmad-project-context/customize.toml +0 -24
  94. package/src/bmm-skills/plan/bmad-project-context/references/best-practices.md +0 -84
  95. package/src/bmm-skills/plan/bmad-project-context/references/template.md +0 -55
  96. package/src/bmm-skills/plan/bmad-spec/SKILL.md +0 -160
  97. package/src/bmm-skills/plan/bmad-spec/assets/headless-schemas.md +0 -33
  98. package/src/bmm-skills/plan/bmad-spec/assets/spec-template.md +0 -49
  99. package/src/bmm-skills/plan/bmad-spec/assets/stories-schema.md +0 -44
  100. package/src/bmm-skills/plan/bmad-spec/customize.toml +0 -52
  101. package/src/bmm-skills/plan/bmad-sprint-planning/SKILL.md +0 -62
  102. package/src/bmm-skills/plan/bmad-sprint-planning/customize.toml +0 -39
  103. package/src/bmm-skills/plan/bmad-sprint-planning/references/fix-sprint-status.md +0 -30
  104. package/src/bmm-skills/plan/bmad-sprint-planning/references/generate-tracking.md +0 -25
  105. package/src/bmm-skills/plan/bmad-sprint-planning/references/readiness-gate.md +0 -20
  106. package/src/bmm-skills/plan/bmad-sprint-planning/references/status-view.md +0 -14
  107. package/src/bmm-skills/plan/bmad-sprint-planning/references/validate.md +0 -10
  108. package/src/bmm-skills/plan/bmad-sprint-planning/scripts/__pycache__/sprint_plan.cpython-311.pyc +0 -0
  109. package/src/bmm-skills/plan/bmad-sprint-planning/scripts/sprint_plan.py +0 -701
  110. package/src/bmm-skills/plan/bmad-sprint-planning/scripts/tests/__pycache__/test_sprint_plan.cpython-311-pytest-9.1.1.pyc +0 -0
  111. package/src/bmm-skills/plan/bmad-sprint-planning/scripts/tests/test_sprint_plan.py +0 -524
  112. package/src/bmm-skills/plan/bmad-sprint-planning/sprint-status-template.yaml +0 -71
  113. package/src/bmm-skills/plan/bmad-ux/SKILL.md +0 -90
  114. package/src/bmm-skills/plan/bmad-ux/assets/color-themes.md +0 -9
  115. package/src/bmm-skills/plan/bmad-ux/assets/design-directions.md +0 -9
  116. package/src/bmm-skills/plan/bmad-ux/assets/design-example-editorial.md +0 -158
  117. package/src/bmm-skills/plan/bmad-ux/assets/design-example-mobile.md +0 -93
  118. package/src/bmm-skills/plan/bmad-ux/assets/design-example-shadcn.md +0 -109
  119. package/src/bmm-skills/plan/bmad-ux/assets/excalidraw-wireframe.md +0 -19
  120. package/src/bmm-skills/plan/bmad-ux/assets/experience-example-mobile.md +0 -112
  121. package/src/bmm-skills/plan/bmad-ux/assets/experience-example-shadcn.md +0 -133
  122. package/src/bmm-skills/plan/bmad-ux/assets/headless-schemas.md +0 -84
  123. package/src/bmm-skills/plan/bmad-ux/assets/key-screens.md +0 -29
  124. package/src/bmm-skills/plan/bmad-ux/assets/validation-report-template.html +0 -319
  125. package/src/bmm-skills/plan/bmad-ux/customize.toml +0 -100
  126. package/src/bmm-skills/plan/bmad-ux/references/creative-tools.md +0 -19
  127. package/src/bmm-skills/plan/bmad-ux/references/design-md-spec.md +0 -50
  128. package/src/bmm-skills/plan/bmad-ux/references/headless.md +0 -37
  129. package/src/bmm-skills/plan/bmad-ux/references/validate.md +0 -115
  130. package/src/bmm-skills/ship/bmad-build/SKILL.md +0 -13
  131. package/src/bmm-skills/ship/bmad-build/compile-epic-context.md +0 -62
  132. package/src/bmm-skills/ship/bmad-build/customize.toml +0 -152
  133. package/src/bmm-skills/ship/bmad-build/references/claims-check.md +0 -14
  134. package/src/bmm-skills/ship/bmad-build/references/deletion-check.md +0 -14
  135. package/src/bmm-skills/ship/bmad-build/review-prompts/edge-case-hunter.md +0 -112
  136. package/src/bmm-skills/ship/bmad-build/review-prompts/verification-gap.md +0 -113
  137. package/src/bmm-skills/ship/bmad-build/spec-template.md +0 -111
  138. package/src/bmm-skills/ship/bmad-build/step-01-clarify-and-route.md +0 -100
  139. package/src/bmm-skills/ship/bmad-build/step-02-plan.md +0 -62
  140. package/src/bmm-skills/ship/bmad-build/step-03-implement.md +0 -51
  141. package/src/bmm-skills/ship/bmad-build/step-04-review.md +0 -85
  142. package/src/bmm-skills/ship/bmad-build/step-05-present.md +0 -43
  143. package/src/bmm-skills/ship/bmad-build/step-oneshot.md +0 -107
  144. package/src/bmm-skills/ship/bmad-build/sync-sprint-status.md +0 -5
  145. package/src/bmm-skills/ship/bmad-build/workflow.md +0 -84
  146. package/src/bmm-skills/ship/bmad-build-auto/SKILL.md +0 -13
  147. package/src/bmm-skills/ship/bmad-build-auto/compile-epic-context.md +0 -62
  148. package/src/bmm-skills/ship/bmad-build-auto/customize.toml +0 -119
  149. package/src/bmm-skills/ship/bmad-build-auto/references/claims-check.md +0 -14
  150. package/src/bmm-skills/ship/bmad-build-auto/references/deletion-check.md +0 -14
  151. package/src/bmm-skills/ship/bmad-build-auto/review-prompts/edge-case-hunter.md +0 -112
  152. package/src/bmm-skills/ship/bmad-build-auto/review-prompts/verification-gap.md +0 -113
  153. package/src/bmm-skills/ship/bmad-build-auto/spec-template.md +0 -96
  154. package/src/bmm-skills/ship/bmad-build-auto/step-01-clarify-and-route.md +0 -84
  155. package/src/bmm-skills/ship/bmad-build-auto/step-02-plan.md +0 -27
  156. package/src/bmm-skills/ship/bmad-build-auto/step-03-implement.md +0 -48
  157. package/src/bmm-skills/ship/bmad-build-auto/step-04-review.md +0 -116
  158. package/src/bmm-skills/ship/bmad-build-auto/workflow.md +0 -104
  159. package/src/bmm-skills/ship/bmad-code-review/SKILL.md +0 -90
  160. package/src/bmm-skills/ship/bmad-code-review/customize.toml +0 -110
  161. package/src/bmm-skills/ship/bmad-code-review/references/claims-check.md +0 -14
  162. package/src/bmm-skills/ship/bmad-code-review/references/deletion-check.md +0 -14
  163. package/src/bmm-skills/ship/bmad-code-review/review-prompts/edge-case-hunter.md +0 -112
  164. package/src/bmm-skills/ship/bmad-code-review/review-prompts/verification-gap.md +0 -113
  165. package/src/bmm-skills/ship/bmad-code-review/steps/step-01-gather-context.md +0 -94
  166. package/src/bmm-skills/ship/bmad-code-review/steps/step-02-review.md +0 -32
  167. package/src/bmm-skills/ship/bmad-code-review/steps/step-03-triage.md +0 -54
  168. package/src/bmm-skills/ship/bmad-code-review/steps/step-04-present.md +0 -134
  169. package/src/bmm-skills/ship/bmad-correct-course/SKILL.md +0 -308
  170. package/src/bmm-skills/ship/bmad-correct-course/checklist.md +0 -288
  171. package/src/bmm-skills/ship/bmad-correct-course/customize.toml +0 -39
  172. package/src/bmm-skills/ship/bmad-qa-generate-e2e-tests/SKILL.md +0 -176
  173. package/src/bmm-skills/ship/bmad-qa-generate-e2e-tests/checklist.md +0 -33
  174. package/src/bmm-skills/ship/bmad-qa-generate-e2e-tests/customize.toml +0 -39
  175. package/src/bmm-skills/ship/bmad-retrospective/SKILL.md +0 -94
  176. package/src/bmm-skills/ship/bmad-retrospective/customize.toml +0 -39
  177. package/src/bmm-skills/ship/bmad-retrospective/references/acceptance-verdict.md +0 -55
  178. package/src/bmm-skills/ship/bmad-retrospective/references/aggregate-views.md +0 -17
  179. package/src/bmm-skills/ship/bmad-retrospective/references/evidence-gathering.md +0 -30
  180. package/src/bmm-skills/ship/bmad-retrospective/references/retro-document.md +0 -84
  181. package/src/bmm-skills/ship/bmad-retrospective/references/team-discussion.md +0 -22
  182. package/src/bmm-skills/ship/bmad-retrospective/scripts/__pycache__/sprint_status.cpython-311.pyc +0 -0
  183. package/src/bmm-skills/ship/bmad-retrospective/scripts/git_evidence.py +0 -308
  184. package/src/bmm-skills/ship/bmad-retrospective/scripts/sprint_status.py +0 -750
  185. package/src/bmm-skills/ship/bmad-retrospective/scripts/tests/__pycache__/test_git_evidence.cpython-311-pytest-9.1.1.pyc +0 -0
  186. package/src/bmm-skills/ship/bmad-retrospective/scripts/tests/__pycache__/test_sprint_status.cpython-311-pytest-9.1.1.pyc +0 -0
  187. package/src/bmm-skills/ship/bmad-retrospective/scripts/tests/fixtures/sprint-status-template.yaml +0 -71
  188. package/src/bmm-skills/ship/bmad-retrospective/scripts/tests/test_git_evidence.py +0 -750
  189. package/src/bmm-skills/ship/bmad-retrospective/scripts/tests/test_sprint_status.py +0 -1579
  190. package/src/bmm-skills/ship/bmad-walkthrough/SKILL.md +0 -68
  191. package/src/bmm-skills/ship/bmad-walkthrough/customize.toml +0 -39
  192. package/src/bmm-skills/ship/bmad-walkthrough/generate-trail.md +0 -38
  193. package/src/bmm-skills/ship/bmad-walkthrough/step-01-orientation.md +0 -105
  194. package/src/bmm-skills/ship/bmad-walkthrough/step-02-walkthrough.md +0 -89
  195. package/src/bmm-skills/ship/bmad-walkthrough/step-03-detail-pass.md +0 -106
  196. package/src/bmm-skills/ship/bmad-walkthrough/step-04-testing.md +0 -74
  197. package/src/bmm-skills/ship/bmad-walkthrough/step-05-wrapup.md +0 -30
  198. package/src/bmm-skills/v6-shims/README.md +0 -29
  199. package/src/bmm-skills/v6-shims/bmad-checkpoint-preview/SKILL.md +0 -21
  200. package/src/bmm-skills/v6-shims/bmad-create-architecture/SKILL.md +0 -32
  201. package/src/bmm-skills/v6-shims/bmad-create-architecture/customize.toml +0 -39
  202. package/src/bmm-skills/v6-shims/bmad-create-prd/SKILL.md +0 -32
  203. package/src/bmm-skills/v6-shims/bmad-create-prd/customize.toml +0 -39
  204. package/src/bmm-skills/v6-shims/bmad-create-story/SKILL.md +0 -436
  205. package/src/bmm-skills/v6-shims/bmad-create-story/checklist.md +0 -357
  206. package/src/bmm-skills/v6-shims/bmad-create-story/customize.toml +0 -39
  207. package/src/bmm-skills/v6-shims/bmad-create-story/discover-inputs.md +0 -88
  208. package/src/bmm-skills/v6-shims/bmad-create-story/template.md +0 -49
  209. package/src/bmm-skills/v6-shims/bmad-dev-auto/SKILL.md +0 -21
  210. package/src/bmm-skills/v6-shims/bmad-dev-story/SKILL.md +0 -504
  211. package/src/bmm-skills/v6-shims/bmad-dev-story/checklist.md +0 -80
  212. package/src/bmm-skills/v6-shims/bmad-dev-story/customize.toml +0 -39
  213. package/src/bmm-skills/v6-shims/bmad-document-project/SKILL.md +0 -16
  214. package/src/bmm-skills/v6-shims/bmad-domain-research/SKILL.md +0 -16
  215. package/src/bmm-skills/v6-shims/bmad-edit-prd/SKILL.md +0 -32
  216. package/src/bmm-skills/v6-shims/bmad-edit-prd/customize.toml +0 -40
  217. package/src/bmm-skills/v6-shims/bmad-market-research/SKILL.md +0 -16
  218. package/src/bmm-skills/v6-shims/bmad-quick-dev/SKILL.md +0 -21
  219. package/src/bmm-skills/v6-shims/bmad-sprint-status/SKILL.md +0 -28
  220. package/src/bmm-skills/v6-shims/bmad-sprint-status/customize.toml +0 -39
  221. package/src/bmm-skills/v6-shims/bmad-technical-research/SKILL.md +0 -16
  222. package/src/bmm-skills/v6-shims/bmad-validate-prd/SKILL.md +0 -32
  223. package/src/bmm-skills/v6-shims/bmad-validate-prd/customize.toml +0 -40
  224. package/src/core-skills/bmad-advanced-elicitation/SKILL.md +0 -64
  225. package/src/core-skills/bmad-advanced-elicitation/assets/methods.csv +0 -72
  226. package/src/core-skills/bmad-advanced-elicitation/customize.toml +0 -54
  227. package/src/core-skills/bmad-advanced-elicitation/scripts/pick_methods.py +0 -233
  228. package/src/core-skills/bmad-advanced-elicitation/scripts/tests/test_pick_methods.py +0 -228
  229. package/src/core-skills/bmad-brainstorming/SKILL.md +0 -80
  230. package/src/core-skills/bmad-brainstorming/assets/brain-icons.json +0 -166
  231. package/src/core-skills/bmad-brainstorming/assets/brain-methods.csv +0 -109
  232. package/src/core-skills/bmad-brainstorming/assets/brain-selector.html +0 -328
  233. package/src/core-skills/bmad-brainstorming/customize.toml +0 -83
  234. package/src/core-skills/bmad-brainstorming/references/converge.md +0 -24
  235. package/src/core-skills/bmad-brainstorming/references/finalize.md +0 -26
  236. package/src/core-skills/bmad-brainstorming/references/headless.md +0 -54
  237. package/src/core-skills/bmad-brainstorming/references/in-chat-techniques.md +0 -18
  238. package/src/core-skills/bmad-brainstorming/references/mode-autonomous.md +0 -10
  239. package/src/core-skills/bmad-brainstorming/references/mode-facilitator.md +0 -11
  240. package/src/core-skills/bmad-brainstorming/references/mode-partner.md +0 -16
  241. package/src/core-skills/bmad-brainstorming/references/resume.md +0 -5
  242. package/src/core-skills/bmad-brainstorming/scripts/brain.py +0 -789
  243. package/src/core-skills/bmad-brainstorming/scripts/tests/test_brain.py +0 -289
  244. package/src/core-skills/bmad-customize/SKILL.md +0 -111
  245. package/src/core-skills/bmad-customize/scripts/list_customizable_skills.py +0 -235
  246. package/src/core-skills/bmad-customize/scripts/tests/test_list_customizable_skills.py +0 -249
  247. package/src/core-skills/bmad-deep-recon/SKILL.md +0 -82
  248. package/src/core-skills/bmad-deep-recon/assets/research.template.md +0 -18
  249. package/src/core-skills/bmad-deep-recon/customize.toml +0 -212
  250. package/src/core-skills/bmad-deep-recon/references/draft.md +0 -8
  251. package/src/core-skills/bmad-deep-recon/references/finalize.md +0 -11
  252. package/src/core-skills/bmad-deep-recon/references/html-briefing.md +0 -16
  253. package/src/core-skills/bmad-deep-recon/references/lifecycle.md +0 -11
  254. package/src/core-skills/bmad-deep-recon/references/process.md +0 -10
  255. package/src/core-skills/bmad-deep-recon/references/run.md +0 -73
  256. package/src/core-skills/bmad-deep-recon/references/selection.md +0 -13
  257. package/src/core-skills/bmad-deep-recon/references/synthesis.md +0 -16
  258. package/src/core-skills/bmad-deep-recon/references/verification.md +0 -29
  259. package/src/core-skills/bmad-deep-recon/scripts/recon_kit.py +0 -326
  260. package/src/core-skills/bmad-deep-recon/scripts/tests/test_recon_kit.py +0 -144
  261. package/src/core-skills/bmad-deep-recon/types/academic-lit.md +0 -19
  262. package/src/core-skills/bmad-deep-recon/types/competitive.md +0 -19
  263. package/src/core-skills/bmad-deep-recon/types/domain.md +0 -19
  264. package/src/core-skills/bmad-deep-recon/types/market.md +0 -19
  265. package/src/core-skills/bmad-deep-recon/types/technical.md +0 -19
  266. package/src/core-skills/bmad-deep-recon/types/user-voice.md +0 -19
  267. package/src/core-skills/bmad-forge-idea/SKILL.md +0 -107
  268. package/src/core-skills/bmad-forge-idea/customize.toml +0 -41
  269. package/src/core-skills/bmad-forge-idea/scripts/resolve_personas.py +0 -277
  270. package/src/core-skills/bmad-forge-idea/scripts/tests/test_resolve_personas.py +0 -160
  271. package/src/core-skills/bmad-help/SKILL.md +0 -77
  272. package/src/core-skills/bmad-party-mode/SKILL.md +0 -60
  273. package/src/core-skills/bmad-party-mode/customize.toml +0 -211
  274. package/src/core-skills/bmad-party-mode/references/create-party.md +0 -70
  275. package/src/core-skills/bmad-party-mode/references/mode-agent-team.md +0 -13
  276. package/src/core-skills/bmad-party-mode/references/mode-auto.md +0 -13
  277. package/src/core-skills/bmad-party-mode/references/mode-subagent.md +0 -31
  278. package/src/core-skills/bmad-party-mode/references/party-memory.md +0 -51
  279. package/src/core-skills/bmad-party-mode/scripts/resolve_party.py +0 -300
  280. package/src/core-skills/bmad-party-mode/scripts/tests/test_resolve_party.py +0 -183
  281. package/src/core-skills/bmad-review/SKILL.md +0 -50
  282. package/src/core-skills/bmad-review/customize.toml +0 -141
  283. package/src/core-skills/bmad-review/references/editorial-common.md +0 -56
  284. package/src/core-skills/bmad-review/references/lens-adversarial.md +0 -19
  285. package/src/core-skills/bmad-review/references/lens-edge-case-hunter.md +0 -72
  286. package/src/core-skills/bmad-review/references/lens-prose.md +0 -7
  287. package/src/core-skills/bmad-review/references/lens-structure.md +0 -9
  288. package/src/core-skills/bmad-review/references/lens-verification-gap.md +0 -92
  289. package/src/core-skills/bmad-review/references/structure-models.md +0 -44
  290. package/src/core-skills/bmad-review/scripts/tests/test_word_metrics.py +0 -62
  291. package/src/core-skills/bmad-review/scripts/word_metrics.py +0 -102
  292. package/src/core-skills/module-help.csv +0 -10
  293. package/src/core-skills/module.yaml +0 -38
  294. package/src/core-skills/v6-shims/README.md +0 -25
  295. package/src/core-skills/v6-shims/bmad-editorial-review/SKILL.md +0 -8
  296. package/src/core-skills/v6-shims/bmad-editorial-review/customize.toml +0 -31
  297. package/src/core-skills/v6-shims/bmad-editorial-review-prose/SKILL.md +0 -8
  298. package/src/core-skills/v6-shims/bmad-editorial-review-structure/SKILL.md +0 -8
  299. package/src/core-skills/v6-shims/bmad-review-adversarial-general/SKILL.md +0 -8
  300. package/src/core-skills/v6-shims/bmad-review-edge-case-hunter/SKILL.md +0 -8
  301. package/src/core-skills/v6-shims/bmad-review-verification-gap/SKILL.md +0 -8
  302. package/src/scripts/__pycache__/config_utils.cpython-311.pyc +0 -0
  303. package/src/scripts/config_utils.py +0 -119
  304. package/src/scripts/memlog.py +0 -228
  305. package/src/scripts/render_skill.py +0 -401
  306. package/src/scripts/resolve_config.py +0 -82
  307. package/src/scripts/resolve_customization.py +0 -164
  308. package/src/scripts/tests/__pycache__/test_config_utils.cpython-311.pyc +0 -0
  309. package/src/scripts/tests/__pycache__/test_resolve_config.cpython-311.pyc +0 -0
  310. package/src/scripts/tests/__pycache__/test_resolve_customization.cpython-311.pyc +0 -0
  311. package/src/scripts/tests/test_config_utils.py +0 -85
  312. package/src/scripts/tests/test_memlog.py +0 -306
  313. package/src/scripts/tests/test_resolve_config.py +0 -117
  314. package/src/scripts/tests/test_resolve_customization.py +0 -179
  315. package/tools/bundle-web-bundles.js +0 -117
  316. package/tools/format-workflow-md.js +0 -263
  317. package/tools/installer/README.md +0 -60
  318. package/tools/installer/bmad-cli.js +0 -105
  319. package/tools/installer/cli-utils.js +0 -57
  320. package/tools/installer/commands/install.js +0 -151
  321. package/tools/installer/commands/status.js +0 -65
  322. package/tools/installer/commands/uninstall.js +0 -167
  323. package/tools/installer/core/config.js +0 -76
  324. package/tools/installer/core/existing-install.js +0 -121
  325. package/tools/installer/core/install-paths.js +0 -132
  326. package/tools/installer/core/installer.js +0 -1826
  327. package/tools/installer/core/legacy-warnings.js +0 -151
  328. package/tools/installer/core/manifest-generator.js +0 -883
  329. package/tools/installer/core/manifest.js +0 -439
  330. package/tools/installer/core/shim-policy.js +0 -159
  331. package/tools/installer/core/uv-check.js +0 -195
  332. package/tools/installer/core/wsl-node-check.js +0 -109
  333. package/tools/installer/file-ops.js +0 -204
  334. package/tools/installer/fs-native.js +0 -116
  335. package/tools/installer/ide/_config-driven.js +0 -972
  336. package/tools/installer/ide/manager.js +0 -324
  337. package/tools/installer/ide/platform-codes.js +0 -80
  338. package/tools/installer/ide/platform-codes.yaml +0 -363
  339. package/tools/installer/ide/shared/installed-skills.js +0 -50
  340. package/tools/installer/ide/shared/path-utils.js +0 -219
  341. package/tools/installer/ide/shared/skill-manifest.js +0 -57
  342. package/tools/installer/install-messages.yaml +0 -44
  343. package/tools/installer/list-options.js +0 -210
  344. package/tools/installer/message-loader.js +0 -83
  345. package/tools/installer/modules/channel-plan.js +0 -216
  346. package/tools/installer/modules/channel-resolver.js +0 -241
  347. package/tools/installer/modules/custom-module-manager.js +0 -924
  348. package/tools/installer/modules/external-manager.js +0 -673
  349. package/tools/installer/modules/git-env.js +0 -47
  350. package/tools/installer/modules/module-help-schema.js +0 -13
  351. package/tools/installer/modules/official-modules.js +0 -2289
  352. package/tools/installer/modules/plugin-resolver.js +0 -398
  353. package/tools/installer/modules/version-resolver.js +0 -336
  354. package/tools/installer/project-root.js +0 -224
  355. package/tools/installer/prompts.js +0 -804
  356. package/tools/installer/set-overrides.js +0 -330
  357. package/tools/installer/ui.js +0 -2262
  358. package/tools/installer/yaml-format.js +0 -245
  359. package/tools/javascript-conventions.md +0 -5
  360. package/tools/migrate-custom-module-paths.js +0 -124
  361. package/tools/skill-validator.md +0 -312
  362. package/tools/tests/__pycache__/test_validate_skills.cpython-311.pyc +0 -0
  363. package/tools/tests/fixtures/validate-skills/bmad/SKILL.md +0 -8
  364. package/tools/tests/fixtures/validate-skills/deprecated-shim/SKILL.md +0 -9
  365. package/tools/tests/fixtures/validate-skills/missing-trigger/SKILL.md +0 -9
  366. package/tools/tests/fixtures/validate-skills/with-trigger/SKILL.md +0 -8
  367. package/tools/tests/test_validate_skills.py +0 -476
  368. package/tools/validate-published-implementation-model.mjs +0 -59
  369. package/tools/validate-sidebar-order.js +0 -388
  370. package/tools/validate-svg-changes.sh +0 -356
  371. package/tools/validate_skills.py +0 -698
  372. package/web-bundles/README.md +0 -46
  373. package/web-bundles/brainstorming-coach/INSTRUCTIONS.md +0 -86
  374. package/web-bundles/brainstorming-coach/SKILL.md +0 -83
  375. package/web-bundles/brainstorming-coach/brain-methods.csv +0 -62
  376. package/web-bundles/bundles.json +0 -139
  377. package/web-bundles/market-and-industry-research/INSTRUCTIONS.md +0 -88
  378. package/web-bundles/market-and-industry-research/SKILL.md +0 -59
  379. package/web-bundles/prd-coach/INSTRUCTIONS.md +0 -86
  380. package/web-bundles/prd-coach/SKILL.md +0 -101
  381. package/web-bundles/prd-coach/prd-template.md +0 -165
  382. package/web-bundles/prd-coach/prd-validation-checklist.md +0 -135
  383. package/web-bundles/prfaq-coach/INSTRUCTIONS.md +0 -86
  384. package/web-bundles/prfaq-coach/SKILL.md +0 -139
  385. package/web-bundles/product-brief-coach/INSTRUCTIONS.md +0 -86
  386. package/web-bundles/product-brief-coach/SKILL.md +0 -113
  387. package/web-bundles/ux-coach/INSTRUCTIONS.md +0 -92
  388. package/web-bundles/ux-coach/SKILL.md +0 -187
  389. package/web-bundles/ux-coach/ux-validation.md +0 -100
package/src/report.js ADDED
@@ -0,0 +1,199 @@
1
+ import { SETUP_NEXT } from './bmad-scripts.js'
2
+ import { message } from './messages.js'
3
+ import { findModule } from './modules.js'
4
+
5
+ /** @typedef {import('./bmad-scripts.js').StatusReport} StatusReport */
6
+ /** @typedef {import('./bmad-scripts.js').Migration} Migration */
7
+ /** @typedef {import('./skills-cli.js').AddResult} AddResult */
8
+ /** @typedef {import('./modules.js').ModuleDefinition} ModuleDefinition */
9
+ /** @typedef {Record<string, any>} Messages */
10
+
11
+ /**
12
+ * @param {StatusReport} report
13
+ * @param {{ failures: AddResult[], messages: Messages, modules?: ModuleDefinition[] }} options
14
+ * @returns {string}
15
+ */
16
+ export function renderStatus(report, options) {
17
+ const { failures, messages, modules = [] } = options
18
+ const lines = [message(messages, 'reportTitle')]
19
+
20
+ lines.push(
21
+ report.current
22
+ ? message(messages, 'reportCurrent')
23
+ : message(messages, 'reportNotCurrent', { next: report.next ?? '' }),
24
+ )
25
+
26
+ for (const module of report.modules) {
27
+ lines.push(
28
+ message(messages, 'reportModule', {
29
+ name: moduleName(modules, module.module),
30
+ version: module.version,
31
+ count: module.skills.length,
32
+ }),
33
+ )
34
+ if (module.absent_skills.length > 0) {
35
+ lines.push(
36
+ message(messages, 'reportAlsoAvailable', {
37
+ skills: module.absent_skills.join(', '),
38
+ code: module.module,
39
+ }),
40
+ )
41
+ }
42
+ }
43
+
44
+ if (report.pending_questions.length > 0) {
45
+ lines.push(message(messages, 'reportPendingQuestions', { count: report.pending_questions.length }))
46
+ }
47
+ lines.push(...problemLines(report, failures, messages))
48
+
49
+ return lines.join('\n')
50
+ }
51
+
52
+ /**
53
+ * @param {AddResult[]} failures
54
+ * @param {Messages} messages
55
+ * @returns {string}
56
+ */
57
+ export function renderFailures(failures, messages) {
58
+ return failures
59
+ .map((failure) => message(messages, 'reportFailure', {
60
+ skill: failure.name ?? '',
61
+ error: failure.error ?? failure.reason ?? '',
62
+ }))
63
+ .join('\n')
64
+ }
65
+
66
+ /**
67
+ * @param {Migration[]} migrations
68
+ * @param {Messages} messages
69
+ * @returns {string}
70
+ */
71
+ export function renderMigrations(migrations, messages) {
72
+ if (migrations.length === 0) return ''
73
+ const lines = [message(messages, 'migrationsAvailable')]
74
+ for (const migration of migrations) {
75
+ lines.push(
76
+ message(messages, 'migrationLine', {
77
+ title: migration.title,
78
+ module: migration.module,
79
+ from: migration.from,
80
+ to: migration.to,
81
+ }),
82
+ )
83
+ }
84
+ return lines.join('\n')
85
+ }
86
+
87
+ /**
88
+ * What failed or is still missing, one line each; empty when nothing is wrong.
89
+ * @param {StatusReport | null} report
90
+ * @param {AddResult[]} failures
91
+ * @param {Messages} messages
92
+ * @returns {string[]}
93
+ */
94
+ export function problemLines(report, failures, messages) {
95
+ const lines = []
96
+ if (failures.length > 0) lines.push(renderFailures(failures, messages))
97
+ if (!report) return lines
98
+ for (const record of report.missing_module_records) {
99
+ lines.push(message(messages, 'reportMissingRecord', { install: record.install ?? '' }))
100
+ }
101
+ for (const unmet of [...report.unmet_requirements, ...report.unmet_recommendations]) {
102
+ lines.push(message(messages, 'reportUnmet', {
103
+ skill: unmet.skill,
104
+ requires: unmet.requires,
105
+ minimum: unmet.minimum ?? '',
106
+ state: unmet.state,
107
+ install: unmet.install ?? '',
108
+ }))
109
+ }
110
+ for (const problem of report.problems) {
111
+ lines.push(message(messages, 'reportProblem', { message: problem.message }))
112
+ }
113
+ return lines
114
+ }
115
+
116
+ /**
117
+ * The closing summary of an install or update: where, which modules, which agents, what next.
118
+ * When `report` is null (e.g. without uv), module names come from `fallbackModules` without versions.
119
+ * @param {StatusReport | null} report
120
+ * @param {{ messages: Messages, modules: ModuleDefinition[], directory: string, agents?: string[], problems: boolean, updated?: boolean, fallbackModules?: string[] }} options
121
+ * @returns {{ title: string, body: string }}
122
+ */
123
+ export function renderSummary(report, options) {
124
+ const { messages, modules, directory, agents, problems, updated, fallbackModules = [] } = options
125
+ const installed = report
126
+ ? groupedModules(report, modules, messages)
127
+ : fallbackModules.map((code) => shortModuleName(modules, code)).join(', ')
128
+ const lines = [
129
+ message(messages, 'summaryProject', { directory }),
130
+ message(messages, 'summaryModules', { modules: installed }),
131
+ ]
132
+ if (agents) lines.push(message(messages, 'summaryAgents', { agents: agents.join(', ') }))
133
+ lines.push('')
134
+ if (!report) lines.push(message(messages, 'summaryNextSetup'))
135
+ else if (report.current) lines.push(message(messages, 'summaryNextCurrent'))
136
+ else if (report.next === SETUP_NEXT) lines.push(message(messages, 'summaryNextSetup'))
137
+ else lines.push(message(messages, 'summaryNextOther', { next: report.next ?? '' }))
138
+ const title = updated ? (problems ? 'summaryTitleUpdatedProblems' : 'summaryTitleUpdated') : (problems ? 'summaryTitleProblems' : 'summaryTitle')
139
+ return { title: message(messages, title), body: lines.join('\n') }
140
+ }
141
+
142
+ /**
143
+ * @param {StatusReport} report
144
+ * @param {ModuleDefinition[]} modules
145
+ * @param {Messages} messages
146
+ * @returns {string}
147
+ */
148
+ function groupedModules(report, modules, messages) {
149
+ /** @type {Map<string, string[]>} */
150
+ const byVersion = new Map()
151
+ for (const entry of report.modules) {
152
+ byVersion.set(entry.version, [...(byVersion.get(entry.version) ?? []), shortModuleName(modules, entry.module)])
153
+ }
154
+ return [...byVersion]
155
+ .map(([version, names]) => message(messages, 'summaryModuleGroup', { names: names.join(', '), version }))
156
+ .join('; ')
157
+ }
158
+
159
+ /**
160
+ * Drops the leading `BMad ` prefix where the surrounding heading already carries the brand.
161
+ * @param {string} name
162
+ * @returns {string}
163
+ */
164
+ export function stripBrandPrefix(name) {
165
+ return name.replace(/^BMad\s+/, '')
166
+ }
167
+
168
+ /**
169
+ * The summary sits under "BMad is installed", so the brand prefix would only push the line past the box width.
170
+ * @param {ModuleDefinition[]} modules
171
+ * @param {string} code
172
+ * @returns {string}
173
+ */
174
+ function shortModuleName(modules, code) {
175
+ return stripBrandPrefix(moduleName(modules, code))
176
+ }
177
+
178
+ /**
179
+ * A module's name with the version it is installed at.
180
+ * @param {Messages} messages
181
+ * @param {string} name
182
+ * @param {string} [version]
183
+ * @returns {string}
184
+ */
185
+ export function installedLabel(messages, name, version) {
186
+ const suffix = version
187
+ ? message(messages, 'installedSuffix', { version })
188
+ : message(messages, 'installedSuffixNoVersion')
189
+ return `${name} ${suffix}`
190
+ }
191
+
192
+ /**
193
+ * @param {ModuleDefinition[]} modules
194
+ * @param {string} code
195
+ * @returns {string}
196
+ */
197
+ function moduleName(modules, code) {
198
+ return findModule(modules, code)?.name ?? code
199
+ }
package/src/run.js ADDED
@@ -0,0 +1,128 @@
1
+ import { randomUUID } from 'node:crypto'
2
+ import { open, readFile, rm } from 'node:fs/promises'
3
+ import { tmpdir } from 'node:os'
4
+ import { join } from 'node:path'
5
+ import spawn from 'cross-spawn'
6
+
7
+ /** @typedef {{ argv: string[], cwd?: string, env?: NodeJS.ProcessEnv, timeoutMs?: number }} RunRequest */
8
+ /** @typedef {{ code: number | null, stdout: string, stderr: string, timedOut: boolean, error?: string }} RunResult */
9
+ /** @typedef {(request: RunRequest) => Promise<RunResult>} Runner */
10
+ /** @typedef {{ fd: number, read(): Promise<string>, dispose(): Promise<void> }} Capture */
11
+
12
+ /**
13
+ * A spawned child's stdout pipe is a socket with an 8 KB buffer, and a child that ends with
14
+ * `process.exit()` drops whatever has not drained. Writes to a regular file always land, so
15
+ * captured stdout goes through a temp file instead.
16
+ * @returns {Promise<Capture>}
17
+ */
18
+ async function openCapture() {
19
+ const path = join(tmpdir(), `bmad-installer-${randomUUID()}`)
20
+ const handle = await open(path, 'w+')
21
+ return {
22
+ fd: handle.fd,
23
+ async read() {
24
+ try {
25
+ return await readFile(path, 'utf8')
26
+ } catch {
27
+ return ''
28
+ }
29
+ },
30
+ async dispose() {
31
+ await handle.close().catch(() => {})
32
+ await rm(path, { force: true }).catch(() => {})
33
+ },
34
+ }
35
+ }
36
+
37
+ /**
38
+ * @param {RunRequest & { capture: Capture }} request
39
+ * @returns {Promise<RunResult>}
40
+ */
41
+ function spawnAndWait(request) {
42
+ const { capture, timeoutMs } = request
43
+ const [command, ...args] = request.argv
44
+
45
+ return new Promise((resolve) => {
46
+ let child
47
+ try {
48
+ child = spawn(command, args, {
49
+ cwd: request.cwd,
50
+ env: request.env,
51
+ stdio: ['ignore', capture.fd, 'pipe'],
52
+ windowsHide: true,
53
+ })
54
+ } catch (err) {
55
+ resolve({ code: null, stdout: '', stderr: '', timedOut: false, error: String(err) })
56
+ return
57
+ }
58
+
59
+ let stderr = ''
60
+ let timedOut = false
61
+ /** @type {NodeJS.Timeout | undefined} */
62
+ let timer
63
+
64
+ child.stderr?.setEncoding('utf8')
65
+ child.stderr?.on('data', (chunk) => { stderr += chunk })
66
+
67
+ if (timeoutMs) {
68
+ timer = setTimeout(() => {
69
+ timedOut = true
70
+ child.kill()
71
+ }, timeoutMs)
72
+ }
73
+
74
+ let settled = false
75
+
76
+ /**
77
+ * @param {number | null} code
78
+ * @param {string} [error]
79
+ */
80
+ const settle = async (code, error) => {
81
+ if (settled) return
82
+ settled = true
83
+ if (timer) clearTimeout(timer)
84
+ const stdout = await capture.read()
85
+ resolve(error === undefined
86
+ ? { code, stdout, stderr, timedOut }
87
+ : { code, stdout, stderr, timedOut, error })
88
+ }
89
+
90
+ child.on('error', (err) => { void settle(null, String(err.message ?? err)) })
91
+ child.on('close', (code) => { void settle(code) })
92
+ })
93
+ }
94
+
95
+ /**
96
+ * @param {{ debug?: boolean, log?: (line: string) => void }} [options]
97
+ * @returns {Runner}
98
+ */
99
+ export function createRunner(options = {}) {
100
+ const debug = options.debug ?? false
101
+ const log = options.log ?? ((line) => process.stderr.write(`${line}\n`))
102
+
103
+ /** @type {Runner} */
104
+ return async function run(request) {
105
+ const { argv, cwd } = request
106
+ if (debug) log(`$ ${cwd ?? process.cwd()}: ${argv.join(' ')}`)
107
+
108
+ /** @type {Capture} */
109
+ let capture
110
+ try {
111
+ capture = await openCapture()
112
+ } catch (err) {
113
+ return { code: null, stdout: '', stderr: '', timedOut: false, error: String(err) }
114
+ }
115
+
116
+ try {
117
+ const result = await spawnAndWait({ ...request, capture })
118
+ if (debug) {
119
+ log(`exit ${result.code}`)
120
+ if (result.stdout) log(result.stdout)
121
+ if (result.stderr) log(result.stderr)
122
+ }
123
+ return result
124
+ } finally {
125
+ await capture.dispose()
126
+ }
127
+ }
128
+ }
@@ -0,0 +1,88 @@
1
+ import { packageName } from './version.js'
2
+
3
+ /** @typedef {import('./run.js').Runner} Runner */
4
+ /** @typedef {{ major: number, minor: number, patch: number, prerelease: string | null }} ParsedVersion */
5
+
6
+ const NPM_VIEW_TIMEOUT_MS = 5000
7
+ const VERSION_PATTERN = /^(\d+)\.(\d+)\.(\d+)(?:-([0-9A-Za-z.-]+))?$/
8
+
9
+ /**
10
+ * @param {string} version
11
+ * @returns {'next' | 'latest'}
12
+ */
13
+ export function distTag(version) {
14
+ return VERSION_PATTERN.exec(version)?.[4] ? 'next' : 'latest'
15
+ }
16
+
17
+ /**
18
+ * @param {string} value
19
+ * @returns {ParsedVersion | null}
20
+ */
21
+ function parseVersion(value) {
22
+ const match = VERSION_PATTERN.exec(value)
23
+ if (!match) return null
24
+ return {
25
+ major: Number(match[1]),
26
+ minor: Number(match[2]),
27
+ patch: Number(match[3]),
28
+ prerelease: match[4] ?? null,
29
+ }
30
+ }
31
+
32
+ /**
33
+ * @param {string} a
34
+ * @param {string} b
35
+ * @returns {number}
36
+ */
37
+ function comparePrerelease(a, b) {
38
+ const left = a.split('.')
39
+ const right = b.split('.')
40
+ for (let index = 0; index < Math.max(left.length, right.length); index += 1) {
41
+ const one = left[index]
42
+ const other = right[index]
43
+ if (one === undefined) return -1
44
+ if (other === undefined) return 1
45
+ if (one === other) continue
46
+ const numeric = /^\d+$/.test(one) && /^\d+$/.test(other)
47
+ return numeric ? Number(one) - Number(other) : one < other ? -1 : 1
48
+ }
49
+ return 0
50
+ }
51
+
52
+ /**
53
+ * @param {ParsedVersion} a
54
+ * @param {ParsedVersion} b
55
+ * @returns {number}
56
+ */
57
+ function compareVersions(a, b) {
58
+ if (a.major !== b.major) return a.major - b.major
59
+ if (a.minor !== b.minor) return a.minor - b.minor
60
+ if (a.patch !== b.patch) return a.patch - b.patch
61
+ if (a.prerelease === b.prerelease) return 0
62
+ if (a.prerelease === null) return 1
63
+ if (b.prerelease === null) return -1
64
+ return comparePrerelease(a.prerelease, b.prerelease)
65
+ }
66
+
67
+ /**
68
+ * @param {{ runner: Runner, version: string, timeoutMs?: number }} deps
69
+ * @returns {Promise<string | null>}
70
+ */
71
+ export async function newerVersion(deps) {
72
+ const { runner, version, timeoutMs = NPM_VIEW_TIMEOUT_MS } = deps
73
+ const ours = parseVersion(version)
74
+ if (!ours) return null
75
+ try {
76
+ const result = await runner({
77
+ argv: ['npm', 'view', `${packageName}@${distTag(version)}`, 'version'],
78
+ timeoutMs,
79
+ })
80
+ if (result.timedOut || result.code !== 0) return null
81
+ const latest = result.stdout.trim()
82
+ const parsed = parseVersion(latest)
83
+ if (!parsed) return null
84
+ return compareVersions(parsed, ours) > 0 ? latest : null
85
+ } catch {
86
+ return null
87
+ }
88
+ }
@@ -0,0 +1,133 @@
1
+ import { createRequire } from 'node:module'
2
+
3
+ /** @typedef {import('./run.js').RunResult} RunResult */
4
+ /** @typedef {import('./run.js').Runner} Runner */
5
+ /** @typedef {{ name?: string, status: 'installed' | 'failed' | 'skipped', error?: string, reason?: string, path?: string, agents?: string[], mode?: string }} AddResult */
6
+ /** @typedef {{ name: string, path: string, scope: 'project' | 'global', agents: string[], source: string | null, status?: 'tracked' | 'modified' | 'untracked' | 'missing' }} ListedSkill */
7
+ /** @typedef {{ source: string, skills: string[], agents: string[] }} AddRequest */
8
+
9
+ export class SkillsCliError extends Error {
10
+ name = 'SkillsCliError'
11
+ }
12
+
13
+ /** @returns {string} */
14
+ export function skillsCliBin() {
15
+ return createRequire(import.meta.url).resolve('skills/bin/cli.mjs')
16
+ }
17
+
18
+ /**
19
+ * @param {NodeJS.ProcessEnv} base
20
+ * @param {{ telemetry: boolean }} options
21
+ * @returns {NodeJS.ProcessEnv}
22
+ */
23
+ export function childEnv(base, options) {
24
+ const env = { ...base }
25
+ if (!options.telemetry) env.DO_NOT_TRACK = '1'
26
+ return env
27
+ }
28
+
29
+ /**
30
+ * `-s` and `-a` swallow every following non-dash token, so `--metadata` comes after them.
31
+ * @param {AddRequest} request
32
+ * @param {{ copy: boolean, metadata: object }} options
33
+ * @returns {string[]}
34
+ */
35
+ export function addArgv(request, options) {
36
+ const argv = [process.execPath, skillsCliBin(), 'add', request.source, '-s', ...request.skills, '-a', ...request.agents]
37
+ argv.push('--metadata', JSON.stringify(options.metadata))
38
+ if (options.copy) argv.push('--copy')
39
+ argv.push('-y', '--json')
40
+ return argv
41
+ }
42
+
43
+ /** @returns {string[]} */
44
+ export function listArgv() {
45
+ return [process.execPath, skillsCliBin(), 'list', '--json']
46
+ }
47
+
48
+ /**
49
+ * @param {string} stdout
50
+ * @returns {AddResult[]}
51
+ */
52
+ export function parseAddResults(stdout) {
53
+ return parseJsonArray(stdout)
54
+ }
55
+
56
+ /**
57
+ * Drops entries from `skills-lock.json` that are not installed on disk (`path: null`, `status: 'missing'`).
58
+ * @param {unknown} entry
59
+ * @returns {entry is ListedSkill}
60
+ */
61
+ export function isInstalledListedSkill(entry) {
62
+ if (!entry || typeof entry !== 'object') return false
63
+ const skill = /** @type {Record<string, unknown>} */ (entry)
64
+ return typeof skill.path === 'string' && skill.path !== '' && skill.status !== 'missing'
65
+ }
66
+
67
+ /**
68
+ * @param {string} stdout
69
+ * @returns {ListedSkill[]}
70
+ */
71
+ export function parseListResults(stdout) {
72
+ return parseJsonArray(stdout).filter(isInstalledListedSkill)
73
+ }
74
+
75
+ /**
76
+ * @param {string} stdout
77
+ * @returns {any[]}
78
+ */
79
+ function parseJsonArray(stdout) {
80
+ let parsed
81
+ try {
82
+ parsed = JSON.parse(stdout)
83
+ } catch {
84
+ throw new SkillsCliError('skills CLI stdout is not JSON')
85
+ }
86
+ if (!Array.isArray(parsed)) throw new SkillsCliError('skills CLI stdout is not a JSON array')
87
+ return parsed
88
+ }
89
+
90
+ /**
91
+ * @param {RunResult} result
92
+ * @returns {string}
93
+ */
94
+ function failureReason(result) {
95
+ const lines = result.stderr.split('\n').map((line) => line.trim()).filter(Boolean)
96
+ return lines.at(-1) ?? `skills CLI exited with code ${result.code}`
97
+ }
98
+
99
+ /**
100
+ * @param {{ runner: Runner, env: NodeJS.ProcessEnv, telemetry: boolean, copy: boolean, metadata: object }} deps
101
+ */
102
+ export function createSkillsCli(deps) {
103
+ const env = childEnv(deps.env, { telemetry: deps.telemetry })
104
+ const { copy, metadata } = deps
105
+
106
+ return {
107
+ /**
108
+ * @param {AddRequest & { cwd: string }} request
109
+ * @returns {Promise<AddResult[]>}
110
+ */
111
+ async add(request) {
112
+ const result = await deps.runner({
113
+ argv: addArgv(request, { copy, metadata }),
114
+ cwd: request.cwd,
115
+ env,
116
+ })
117
+ try {
118
+ return parseAddResults(result.stdout)
119
+ } catch {
120
+ return [{ status: 'failed', error: failureReason(result) }]
121
+ }
122
+ },
123
+ /**
124
+ * @param {{ cwd: string }} options
125
+ * @returns {Promise<ListedSkill[]>}
126
+ */
127
+ async list(options) {
128
+ const result = await deps.runner({ argv: listArgv(), cwd: options.cwd, env })
129
+ if (result.code !== 0 && result.stdout.trim() === '') return []
130
+ return parseListResults(result.stdout)
131
+ },
132
+ }
133
+ }
package/src/version.js ADDED
@@ -0,0 +1,11 @@
1
+ import { createRequire } from 'node:module'
2
+ import { dirname } from 'node:path'
3
+
4
+ const require = createRequire(import.meta.url)
5
+ const packageJson = require('../package.json')
6
+
7
+ export const packageRoot = dirname(require.resolve('../package.json'))
8
+ /** @type {string} */
9
+ export const packageName = packageJson.name
10
+ /** @type {string} */
11
+ export const version = packageJson.version
@@ -1,53 +0,0 @@
1
- {
2
- "name": "bmad-method",
3
- "owner": {
4
- "name": "Brian (BMad) Madison"
5
- },
6
- "description": "Breakthrough Method of Agile AI-driven Development — a full-lifecycle framework with agents and workflows for analysis, planning, architecture, and implementation.",
7
- "license": "MIT",
8
- "homepage": "https://github.com/bmad-code-org/BMAD-METHOD",
9
- "repository": "https://github.com/bmad-code-org/BMAD-METHOD",
10
- "keywords": ["bmad", "agile", "ai", "orchestrator", "development", "methodology", "agents", "brainstorming", "thinking"],
11
- "plugins": [
12
- {
13
- "name": "bmad-method-analyze-plan-build",
14
- "displayName": "BMad Method Analyze Plan Build",
15
- "source": "./",
16
- "description": "Full-lifecycle AI development framework — agents and workflows for product analysis, planning, architecture, and implementation.",
17
- "version": "6.12.4",
18
- "author": {
19
- "name": "Brian (BMad) Madison"
20
- },
21
- "skills": [
22
- "./src/bmm-skills/agents/bmad-agent-analyst",
23
- "./src/bmm-skills/agents/bmad-agent-architect",
24
- "./src/bmm-skills/agents/bmad-agent-dev",
25
- "./src/bmm-skills/agents/bmad-agent-pm",
26
- "./src/bmm-skills/agents/bmad-agent-ux-designer",
27
- "./src/bmm-skills/plan/bmad-architecture",
28
- "./src/bmm-skills/plan/bmad-create-epics-and-stories",
29
- "./src/bmm-skills/plan/bmad-prd",
30
- "./src/bmm-skills/plan/bmad-prfaq",
31
- "./src/bmm-skills/plan/bmad-product-brief",
32
- "./src/bmm-skills/plan/bmad-project-context",
33
- "./src/bmm-skills/plan/bmad-spec",
34
- "./src/bmm-skills/plan/bmad-sprint-planning",
35
- "./src/bmm-skills/plan/bmad-ux",
36
- "./src/bmm-skills/ship/bmad-build",
37
- "./src/bmm-skills/ship/bmad-code-review",
38
- "./src/bmm-skills/ship/bmad-correct-course",
39
- "./src/bmm-skills/ship/bmad-qa-generate-e2e-tests",
40
- "./src/bmm-skills/ship/bmad-retrospective",
41
- "./src/bmm-skills/ship/bmad-walkthrough",
42
- "./src/core-skills/bmad-advanced-elicitation",
43
- "./src/core-skills/bmad-brainstorming",
44
- "./src/core-skills/bmad-customize",
45
- "./src/core-skills/bmad-deep-recon",
46
- "./src/core-skills/bmad-forge-idea",
47
- "./src/core-skills/bmad-help",
48
- "./src/core-skills/bmad-party-mode",
49
- "./src/core-skills/bmad-review"
50
- ]
51
- }
52
- ]
53
- }
package/AGENTS.md DELETED
@@ -1,24 +0,0 @@
1
- # BMAD-METHOD
2
-
3
- Open source framework for structured, agent-assisted software delivery.
4
-
5
- ## Rules
6
-
7
- - Use Conventional Commits for every commit.
8
- - Before pushing, run `npm ci && npm run quality` on `HEAD` in the exact checkout you are about to push.
9
- `quality` mirrors the checks in `.github/workflows/quality.yaml`.
10
-
11
- - Skill validation rules are in `tools/skill-validator.md`.
12
- - Deterministic skill checks run via `npm run validate:skills` (included in `quality`).
13
- - Documentation conventions are in `docs/_STYLE_GUIDE.md`.
14
-
15
- ## Writing prompts
16
-
17
- Skills, workflows, tasks, and agent definitions are prompt text that an agent reads in full on every run. Length and
18
- ambiguity are paid on every run; a corner case is paid only when it occurs. So do not add instructions for exotic
19
- cases — the model usually handles them from context, and the reviewing human can correct it when it does not.
20
-
21
- ## Testing
22
-
23
- Automated tests assert outcomes produced by deterministic code. Do not write automated tests for LLM output or for
24
- static source text.
package/CLAUDE.md DELETED
@@ -1 +0,0 @@
1
- @AGENTS.md