bmad-method 6.0.0-alpha.13 → 6.0.0-alpha.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.github/ISSUE_TEMPLATE/idea_submission.md +1 -1
- package/.github/scripts/discord-helpers.sh +15 -0
- package/.github/workflows/discord.yaml +278 -8
- package/.github/workflows/quality.yaml +19 -0
- package/.markdownlint-cli2.yaml +42 -0
- package/.prettierignore +3 -0
- package/CHANGELOG.md +95 -0
- package/CODE_OF_CONDUCT.md +128 -0
- package/bmad-method-6.0.0-alpha.14.tgz +0 -0
- package/docs/agent-customization-guide.md +2 -2
- package/docs/custom-agent-installation.md +56 -102
- package/docs/document-sharding-guide.md +1 -1
- package/eslint.config.mjs +14 -0
- package/example-custom-content/README.md +4 -0
- package/{custom/src → example-custom-content}/agents/toolsmith/toolsmith-sidecar/instructions.md +4 -4
- package/{custom/src → example-custom-content}/agents/toolsmith/toolsmith-sidecar/memories.md +1 -1
- package/{custom/src → example-custom-content}/agents/toolsmith/toolsmith.agent.yaml +17 -16
- package/example-custom-content/custom.yaml +3 -0
- package/example-custom-content/workflows/quiz-master/steps/step-01-init.md +168 -0
- package/example-custom-content/workflows/quiz-master/steps/step-02-q1.md +155 -0
- package/example-custom-content/workflows/quiz-master/steps/step-03-q2.md +89 -0
- package/example-custom-content/workflows/quiz-master/steps/step-04-q3.md +36 -0
- package/example-custom-content/workflows/quiz-master/steps/step-05-q4.md +36 -0
- package/example-custom-content/workflows/quiz-master/steps/step-06-q5.md +36 -0
- package/example-custom-content/workflows/quiz-master/steps/step-07-q6.md +36 -0
- package/example-custom-content/workflows/quiz-master/steps/step-08-q7.md +36 -0
- package/example-custom-content/workflows/quiz-master/steps/step-09-q8.md +36 -0
- package/example-custom-content/workflows/quiz-master/steps/step-10-q9.md +36 -0
- package/example-custom-content/workflows/quiz-master/steps/step-11-q10.md +36 -0
- package/example-custom-content/workflows/quiz-master/steps/step-12-results.md +150 -0
- package/example-custom-content/workflows/quiz-master/templates/csv-headers.template +1 -0
- package/example-custom-content/workflows/quiz-master/workflow-plan-quiz-master.md +269 -0
- package/example-custom-content/workflows/quiz-master/workflow.md +54 -0
- package/example-custom-content/workflows/wassup/workflow.md +26 -0
- package/example-custom-module/mwm/README.md +4 -0
- package/example-custom-module/mwm/_module-installer/install-config.yaml +27 -0
- package/example-custom-module/mwm/agents/cbt-coach/cbt-coach-sidecar/cognitive-distortions.md +47 -0
- package/example-custom-module/mwm/agents/cbt-coach/cbt-coach-sidecar/thought-records.md +17 -0
- package/example-custom-module/mwm/agents/cbt-coach/cbt-coach.agent.yaml +150 -0
- package/example-custom-module/mwm/agents/crisis-navigator.agent.yaml +137 -0
- package/example-custom-module/mwm/agents/meditation-guide.agent.yaml +137 -0
- package/example-custom-module/mwm/agents/wellness-companion/wellness-companion-sidecar/insights.md +13 -0
- package/example-custom-module/mwm/agents/wellness-companion/wellness-companion-sidecar/instructions.md +30 -0
- package/example-custom-module/mwm/agents/wellness-companion/wellness-companion-sidecar/memories.md +13 -0
- package/example-custom-module/mwm/agents/wellness-companion/wellness-companion-sidecar/patterns.md +17 -0
- package/example-custom-module/mwm/agents/wellness-companion/wellness-companion.agent.yaml +124 -0
- package/example-custom-module/mwm/workflows/cbt-thought-record/README.md +31 -0
- package/example-custom-module/mwm/workflows/cbt-thought-record/workflow.md +45 -0
- package/example-custom-module/mwm/workflows/crisis-support/README.md +31 -0
- package/example-custom-module/mwm/workflows/crisis-support/workflow.md +45 -0
- package/example-custom-module/mwm/workflows/daily-checkin/README.md +32 -0
- package/example-custom-module/mwm/workflows/daily-checkin/workflow.md +45 -0
- package/example-custom-module/mwm/workflows/guided-meditation/README.md +31 -0
- package/example-custom-module/mwm/workflows/guided-meditation/workflow.md +45 -0
- package/example-custom-module/mwm/workflows/wellness-journal/README.md +31 -0
- package/example-custom-module/mwm/workflows/wellness-journal/workflow.md +45 -0
- package/package.json +9 -4
- package/src/core/_module-installer/install-config.yaml +5 -1
- package/src/core/resources/excalidraw/library-loader.md +2 -2
- package/src/core/workflows/brainstorming/steps/step-01-session-setup.md +1 -1
- package/src/core/workflows/brainstorming/workflow.md +1 -1
- package/src/core/workflows/party-mode/steps/step-03-graceful-exit.md +0 -1
- package/src/core/workflows/party-mode/workflow.md +2 -3
- package/src/modules/bmb/README.md +1 -1
- package/src/modules/bmb/_module-installer/install-config.yaml +4 -9
- package/src/modules/bmb/_module-installer/installer.js +76 -0
- package/src/modules/bmb/agents/bmad-builder.agent.yaml +32 -9
- package/src/modules/bmb/docs/agents/agent-menu-patterns.md +5 -5
- package/src/modules/bmb/docs/agents/expert-agent-architecture.md +20 -20
- package/src/modules/bmb/docs/agents/module-agent-architecture.md +45 -45
- package/src/modules/bmb/docs/agents/simple-agent-architecture.md +7 -3
- package/src/modules/bmb/docs/workflows/architecture.md +1 -1
- package/src/modules/bmb/docs/workflows/templates/step-01-init-continuable-template.md +241 -0
- package/src/modules/bmb/docs/workflows/templates/step-1b-template.md +223 -0
- package/src/modules/bmb/{workflows/create-workflow → docs/workflows}/templates/step-file.md +4 -4
- package/src/modules/bmb/docs/workflows/{step-template.md → templates/step-template.md} +40 -33
- package/src/modules/bmb/docs/workflows/templates/workflow-template.md +104 -0
- package/src/modules/bmb/{workflows/create-workflow → docs/workflows}/templates/workflow.md +1 -1
- package/src/modules/bmb/reference/agents/expert-examples/journal-keeper/README.md +4 -4
- package/src/modules/bmb/reference/agents/expert-examples/journal-keeper/journal-keeper.agent.yaml +8 -8
- package/src/modules/bmb/reference/agents/module-examples/security-engineer.agent.yaml +6 -6
- package/src/modules/bmb/reference/agents/module-examples/trend-analyst.agent.yaml +7 -7
- package/src/modules/bmb/reference/workflows/meal-prep-nutrition/steps/step-01-init.md +2 -3
- package/src/modules/bmb/reference/workflows/meal-prep-nutrition/steps/step-01b-continue.md +10 -40
- package/src/modules/bmb/reference/workflows/meal-prep-nutrition/steps/step-02-profile.md +1 -1
- package/src/modules/bmb/reference/workflows/meal-prep-nutrition/steps/step-03-assessment.md +1 -0
- package/src/modules/bmb/reference/workflows/meal-prep-nutrition/steps/step-04-strategy.md +2 -2
- package/src/modules/bmb/reference/workflows/meal-prep-nutrition/steps/step-05-shopping.md +2 -2
- package/src/modules/bmb/reference/workflows/meal-prep-nutrition/steps/step-06-prep-schedule.md +2 -2
- package/src/modules/bmb/reference/workflows/meal-prep-nutrition/workflow.md +2 -2
- package/src/modules/bmb/workflows/create-agent/data/info-and-installation-guide.md +16 -4
- package/src/modules/bmb/workflows/create-agent/data/reference/agents/expert-examples/journal-keeper/README.md +4 -4
- package/src/modules/bmb/workflows/create-agent/data/reference/agents/expert-examples/journal-keeper/journal-keeper.agent.yaml +7 -7
- package/src/modules/bmb/workflows/create-agent/data/reference/workflows/meal-prep-nutrition/steps/step-05-shopping.md +1 -1
- package/src/modules/bmb/workflows/create-agent/data/validation-complete.md +3 -3
- package/src/modules/bmb/workflows/create-agent/steps/step-01-brainstorm.md +3 -3
- package/src/modules/bmb/workflows/create-agent/steps/step-02-discover.md +3 -3
- package/src/modules/bmb/workflows/create-agent/steps/step-03-persona.md +3 -3
- package/src/modules/bmb/workflows/create-agent/steps/step-04-commands.md +6 -6
- package/src/modules/bmb/workflows/create-agent/steps/step-05-name.md +2 -2
- package/src/modules/bmb/workflows/create-agent/steps/step-06-build.md +3 -3
- package/src/modules/bmb/workflows/create-agent/steps/step-07-validate.md +3 -3
- package/src/modules/bmb/workflows/create-agent/steps/step-08-setup.md +2 -2
- package/src/modules/bmb/workflows/create-agent/steps/step-09-customize.md +3 -3
- package/src/modules/bmb/workflows/create-agent/steps/step-10-build-tools.md +2 -2
- package/src/modules/bmb/workflows/create-agent/steps/step-11-celebrate.md +2 -2
- package/src/modules/bmb/workflows/create-agent/workflow.md +11 -11
- package/src/modules/bmb/workflows/create-module/steps/step-01-init.md +155 -0
- package/src/modules/bmb/workflows/create-module/steps/step-01b-continue.md +169 -0
- package/src/modules/bmb/workflows/create-module/steps/step-02-concept.md +217 -0
- package/src/modules/bmb/workflows/create-module/steps/step-03-components.md +267 -0
- package/src/modules/bmb/workflows/create-module/steps/step-04-structure.md +228 -0
- package/src/modules/bmb/workflows/create-module/steps/step-05-config.md +233 -0
- package/src/modules/bmb/workflows/create-module/steps/step-06-agents.md +296 -0
- package/src/modules/bmb/workflows/create-module/steps/step-07-workflows.md +228 -0
- package/src/modules/bmb/workflows/create-module/steps/step-08-installer.md +186 -0
- package/src/modules/bmb/workflows/create-module/steps/step-09-documentation.md +308 -0
- package/src/modules/bmb/workflows/create-module/steps/step-10-roadmap.md +336 -0
- package/src/modules/bmb/workflows/create-module/steps/step-11-validate.md +335 -0
- package/src/modules/bmb/workflows/create-module/templates/agent.template.md +317 -0
- package/src/modules/bmb/workflows/create-module/templates/install-config.template.yaml +53 -0
- package/src/modules/bmb/workflows/create-module/templates/installer.template.js +47 -0
- package/src/modules/bmb/workflows/create-module/templates/module-plan.template.md +5 -0
- package/src/modules/bmb/workflows/create-module/templates/workflow-plan-template.md +23 -0
- package/src/modules/bmb/workflows/create-module/validation.md +126 -0
- package/src/modules/bmb/workflows/create-module/workflow.md +55 -0
- package/src/modules/bmb/workflows/create-workflow/steps/step-01-init.md +45 -56
- package/src/modules/bmb/workflows/create-workflow/steps/step-02-gather.md +9 -31
- package/src/modules/bmb/workflows/create-workflow/steps/step-03-tools-configuration.md +250 -0
- package/src/modules/bmb/workflows/create-workflow/steps/step-04-plan-review.md +216 -0
- package/src/modules/bmb/workflows/create-workflow/steps/step-05-output-format-design.md +289 -0
- package/src/modules/bmb/workflows/create-workflow/steps/{step-09-design.md → step-06-design.md} +76 -44
- package/src/modules/bmb/workflows/create-workflow/steps/{step-11-build.md → step-07-build.md} +70 -24
- package/src/modules/bmb/workflows/create-workflow/steps/{step-12-review.md → step-08-review.md} +30 -16
- package/src/modules/bmb/workflows/create-workflow/steps/step-09-complete.md +187 -0
- package/src/modules/bmb/workflows/create-workflow/workflow.md +2 -2
- package/src/modules/bmb/workflows/edit-agent/steps/step-01-discover-intent.md +2 -2
- package/src/modules/bmb/workflows/edit-agent/steps/step-02-analyze-agent.md +14 -14
- package/src/modules/bmb/workflows/edit-agent/steps/step-03-propose-changes.md +4 -4
- package/src/modules/bmb/workflows/edit-agent/steps/step-04-apply-changes.md +2 -2
- package/src/modules/bmb/workflows/edit-agent/steps/step-05-validate.md +4 -4
- package/src/modules/bmb/workflows/edit-agent/workflow.md +1 -1
- package/src/modules/bmb/workflows/edit-workflow/steps/step-01-analyze.md +2 -6
- package/src/modules/bmb/workflows/edit-workflow/steps/step-03-improve.md +2 -2
- package/src/modules/bmb/workflows/edit-workflow/steps/step-04-validate.md +1 -1
- package/src/modules/bmb/workflows/edit-workflow/workflow.md +1 -1
- package/src/modules/bmb/workflows/workflow-compliance-check/steps/step-01-validate-goal.md +2 -2
- package/src/modules/bmb/workflows/workflow-compliance-check/steps/step-02-workflow-validation.md +5 -5
- package/src/modules/bmb/workflows/workflow-compliance-check/steps/step-03-step-validation.md +7 -7
- package/src/modules/bmb/workflows/workflow-compliance-check/steps/step-04-file-validation.md +3 -3
- package/src/modules/bmb/workflows/workflow-compliance-check/steps/step-05-intent-spectrum-validation.md +3 -3
- package/src/modules/bmb/workflows/workflow-compliance-check/steps/step-06-web-subprocess-validation.md +3 -3
- package/src/modules/bmb/workflows/workflow-compliance-check/steps/step-07-holistic-analysis.md +3 -3
- package/src/modules/bmb/workflows/workflow-compliance-check/steps/step-08-generate-report.md +2 -2
- package/src/modules/bmb/workflows/workflow-compliance-check/workflow.md +1 -1
- package/src/modules/bmb/workflows-legacy/edit-module/checklist.md +0 -1
- package/src/modules/bmgd/workflows/3-technical/game-architecture/instructions.md +8 -8
- package/src/modules/bmm/_module-installer/install-config.yaml +1 -1
- package/src/modules/bmm/agents/analyst.agent.yaml +11 -8
- package/src/modules/bmm/agents/architect.agent.yaml +1 -5
- package/src/modules/bmm/agents/pm.agent.yaml +5 -5
- package/src/modules/bmm/docs/README.md +23 -1
- package/src/modules/bmm/docs/agents-guide.md +16 -35
- package/src/modules/bmm/docs/brownfield-guide.md +17 -30
- package/src/modules/bmm/docs/enterprise-agentic-development.md +2 -2
- package/src/modules/bmm/docs/faq.md +6 -39
- package/src/modules/bmm/docs/glossary.md +11 -24
- package/src/modules/bmm/docs/images/README.md +37 -0
- package/src/modules/bmm/docs/images/workflow-method-greenfield.excalidraw +62 -202
- package/src/modules/bmm/docs/images/workflow-method-greenfield.svg +3 -1
- package/src/modules/bmm/docs/quick-spec-flow.md +652 -0
- package/src/modules/bmm/docs/quick-start.md +9 -25
- package/src/modules/bmm/docs/test-architecture.md +6 -6
- package/src/modules/bmm/docs/troubleshooting.md +680 -0
- package/src/modules/bmm/docs/workflow-document-project-reference.md +1 -1
- package/src/modules/bmm/docs/workflows-implementation.md +143 -3
- package/src/modules/bmm/docs/workflows-solutioning.md +2 -2
- package/src/modules/bmm/tasks/daily-standup.xml +85 -0
- package/src/modules/bmm/testarch/knowledge/ci-burn-in.md +1 -1
- package/src/modules/bmm/testarch/knowledge/overview.md +1 -1
- package/src/modules/bmm/workflows/1-analysis/product-brief/steps/step-02-vision.md +2 -2
- package/src/modules/bmm/workflows/1-analysis/product-brief/steps/step-03-users.md +2 -2
- package/src/modules/bmm/workflows/1-analysis/product-brief/steps/step-04-metrics.md +2 -2
- package/src/modules/bmm/workflows/1-analysis/product-brief/steps/step-05-scope.md +2 -2
- package/src/modules/bmm/workflows/1-analysis/product-brief/workflow.md +1 -1
- package/src/modules/bmm/workflows/1-analysis/research/domain-steps/step-01-init.md +8 -8
- package/src/modules/bmm/workflows/1-analysis/research/domain-steps/step-02-domain-analysis.md +18 -18
- package/src/modules/bmm/workflows/1-analysis/research/domain-steps/step-03-competitive-landscape.md +18 -18
- package/src/modules/bmm/workflows/1-analysis/research/domain-steps/step-04-regulatory-focus.md +18 -18
- package/src/modules/bmm/workflows/1-analysis/research/domain-steps/step-05-technical-trends.md +17 -17
- package/src/modules/bmm/workflows/1-analysis/research/domain-steps/step-06-research-synthesis.md +35 -36
- package/src/modules/bmm/workflows/1-analysis/research/market-steps/step-01-init.md +5 -6
- package/src/modules/bmm/workflows/1-analysis/research/market-steps/step-02-customer-behavior.md +20 -19
- package/src/modules/bmm/workflows/1-analysis/research/market-steps/step-02-customer-insights.md +21 -20
- package/src/modules/bmm/workflows/1-analysis/research/market-steps/step-03-customer-pain-points.md +20 -19
- package/src/modules/bmm/workflows/1-analysis/research/market-steps/step-04-customer-decisions.md +21 -20
- package/src/modules/bmm/workflows/1-analysis/research/market-steps/step-05-competitive-analysis.md +16 -15
- package/src/modules/bmm/workflows/1-analysis/research/market-steps/step-06-research-completion.md +36 -37
- package/src/modules/bmm/workflows/1-analysis/research/research.template.md +0 -1
- package/src/modules/bmm/workflows/1-analysis/research/technical-steps/step-01-init.md +8 -8
- package/src/modules/bmm/workflows/1-analysis/research/technical-steps/step-02-technical-overview.md +19 -18
- package/src/modules/bmm/workflows/1-analysis/research/technical-steps/step-03-integration-patterns.md +20 -19
- package/src/modules/bmm/workflows/1-analysis/research/technical-steps/step-04-architectural-patterns.md +21 -20
- package/src/modules/bmm/workflows/1-analysis/research/technical-steps/step-05-implementation-research.md +19 -18
- package/src/modules/bmm/workflows/1-analysis/research/technical-steps/step-06-research-synthesis.md +38 -39
- package/src/modules/bmm/workflows/1-analysis/research/workflow.md +14 -8
- package/src/modules/bmm/workflows/2-plan-workflows/create-ux-design/workflow.md +6 -0
- package/src/modules/bmm/workflows/2-plan-workflows/prd/prd-template.md +7 -0
- package/src/modules/bmm/workflows/2-plan-workflows/prd/steps/step-01-init.md +138 -56
- package/src/modules/bmm/workflows/2-plan-workflows/prd/steps/step-01b-continue.md +93 -51
- package/src/modules/bmm/workflows/2-plan-workflows/prd/steps/step-02-discovery.md +223 -78
- package/src/modules/bmm/workflows/2-plan-workflows/prd/steps/step-03-success.md +20 -2
- package/src/modules/bmm/workflows/2-plan-workflows/prd/steps/step-04-journeys.md +18 -0
- package/src/modules/bmm/workflows/2-plan-workflows/prd/steps/step-05-domain.md +21 -0
- package/src/modules/bmm/workflows/2-plan-workflows/prd/steps/step-06-innovation.md +21 -0
- package/src/modules/bmm/workflows/2-plan-workflows/prd/steps/step-07-project-type.md +21 -0
- package/src/modules/bmm/workflows/2-plan-workflows/prd/steps/step-08-scoping.md +18 -0
- package/src/modules/bmm/workflows/2-plan-workflows/prd/steps/step-09-functional.md +18 -0
- package/src/modules/bmm/workflows/2-plan-workflows/prd/steps/step-10-nonfunctional.md +18 -0
- package/src/modules/bmm/workflows/2-plan-workflows/prd/steps/step-11-complete.md +13 -0
- package/src/modules/bmm/workflows/2-plan-workflows/prd/workflow.md +2 -2
- package/src/modules/bmm/workflows/3-solutioning/architecture/steps/step-03-starter.md +14 -14
- package/src/modules/bmm/workflows/3-solutioning/architecture/steps/step-04-decisions.md +7 -7
- package/src/modules/bmm/workflows/3-solutioning/architecture/workflow.md +2 -1
- package/src/modules/bmm/workflows/3-solutioning/create-epics-and-stories/steps/step-01-validate-prerequisites.md +258 -0
- package/src/modules/bmm/workflows/3-solutioning/create-epics-and-stories/steps/step-02-design-epics.md +232 -0
- package/src/modules/bmm/workflows/3-solutioning/create-epics-and-stories/steps/step-03-create-stories.md +271 -0
- package/src/modules/bmm/workflows/3-solutioning/create-epics-and-stories/steps/step-04-final-validation.md +144 -0
- package/src/modules/bmm/workflows/3-solutioning/create-epics-and-stories/templates/epics-template.md +57 -0
- package/src/modules/bmm/workflows/3-solutioning/create-epics-and-stories/workflow.md +58 -0
- package/src/modules/bmm/workflows/3-solutioning/implementation-readiness/steps/step-01-document-discovery.md +189 -0
- package/src/modules/bmm/workflows/3-solutioning/implementation-readiness/steps/step-02-prd-analysis.md +177 -0
- package/src/modules/bmm/workflows/3-solutioning/implementation-readiness/steps/step-03-epic-coverage-validation.md +178 -0
- package/src/modules/bmm/workflows/3-solutioning/implementation-readiness/steps/step-04-ux-alignment.md +138 -0
- package/src/modules/bmm/workflows/3-solutioning/implementation-readiness/steps/step-05-epic-quality-review.md +251 -0
- package/src/modules/bmm/workflows/3-solutioning/implementation-readiness/steps/step-06-final-assessment.md +132 -0
- package/src/modules/bmm/workflows/3-solutioning/implementation-readiness/templates/readiness-report-template.md +4 -0
- package/src/modules/bmm/workflows/3-solutioning/implementation-readiness/workflow.md +54 -0
- package/src/modules/{bmgd/workflows/4-production → bmm/workflows/4-implementation}/code-review/checklist.md +2 -1
- package/src/modules/bmm/workflows/4-implementation/code-review/instructions.xml +51 -3
- package/src/modules/bmm/workflows/4-implementation/code-review/workflow.yaml +1 -1
- package/src/modules/bmm/workflows/4-implementation/create-story/instructions.xml +32 -2
- package/src/modules/bmm/workflows/4-implementation/retrospective/instructions.md +3 -3
- package/src/modules/bmm/workflows/4-implementation/sprint-planning/instructions.md +19 -21
- package/src/modules/bmm/workflows/4-implementation/sprint-planning/sprint-status-template.yaml +10 -10
- package/src/modules/bmm/workflows/4-implementation/sprint-status/instructions.md +174 -0
- package/src/modules/bmm/workflows/4-implementation/sprint-status/workflow.yaml +35 -0
- package/src/modules/bmm/workflows/bmad-quick-flow/quick-dev/instructions.md +104 -7
- package/src/modules/bmm/workflows/bmad-quick-flow/quick-dev/workflow.yaml +4 -0
- package/src/modules/bmm/workflows/document-project/instructions.md +1 -1
- package/src/modules/bmm/workflows/document-project/workflows/deep-dive-instructions.md +2 -2
- package/src/modules/bmm/workflows/generate-project-context/workflow.md +1 -1
- package/src/modules/bmm/workflows/testarch/atdd/atdd-checklist-template.md +1 -1
- package/src/modules/bmm/workflows/testarch/ci/checklist.md +1 -1
- package/src/modules/bmm/workflows/testarch/ci/github-actions-template.yaml +36 -3
- package/src/modules/bmm/workflows/testarch/ci/gitlab-ci-template.yaml +25 -4
- package/src/modules/bmm/workflows/testarch/ci/instructions.md +2 -2
- package/src/modules/bmm/workflows/testarch/test-review/instructions.md +1 -1
- package/src/modules/bmm/workflows/workflow-status/paths/enterprise-brownfield.yaml +1 -6
- package/src/modules/bmm/workflows/workflow-status/paths/enterprise-greenfield.yaml +1 -6
- package/src/modules/bmm/workflows/workflow-status/paths/method-brownfield.yaml +1 -6
- package/src/modules/bmm/workflows/workflow-status/paths/method-greenfield.yaml +1 -7
- package/tools/cli/README.md +3 -3
- package/tools/cli/commands/build.js +9 -184
- package/tools/cli/commands/install.js +1 -6
- package/tools/cli/installers/lib/core/config-collector.js +70 -10
- package/tools/cli/installers/lib/core/installer.js +153 -388
- package/tools/cli/installers/lib/core/manifest-generator.js +91 -30
- package/tools/cli/installers/lib/core/post-install-sidecar-replacement.js +79 -0
- package/tools/cli/installers/lib/custom/handler.js +266 -0
- package/tools/cli/installers/lib/ide/_base-ide.js +10 -0
- package/tools/cli/installers/lib/ide/auggie.js +19 -7
- package/tools/cli/installers/lib/ide/crush.js +19 -6
- package/tools/cli/installers/lib/ide/cursor.js +29 -13
- package/tools/cli/installers/lib/ide/gemini.js +49 -1
- package/tools/cli/installers/lib/ide/iflow.js +20 -1
- package/tools/cli/installers/lib/ide/kiro-cli.js +327 -0
- package/tools/cli/installers/lib/ide/opencode.js +3 -3
- package/tools/cli/installers/lib/ide/roo.js +120 -184
- package/tools/cli/installers/lib/ide/rovo-dev.js +1 -1
- package/tools/cli/installers/lib/ide/shared/agent-command-generator.js +8 -2
- package/tools/cli/installers/lib/ide/shared/bmad-artifacts.js +34 -19
- package/tools/cli/installers/lib/ide/shared/workflow-command-generator.js +18 -14
- package/tools/cli/installers/lib/ide/templates/agent-command-template.md +1 -1
- package/tools/cli/installers/lib/ide/templates/workflow-commander.md +5 -0
- package/tools/cli/installers/lib/modules/manager.js +486 -53
- package/tools/cli/lib/agent/compiler.js +54 -5
- package/tools/cli/lib/agent/installer.js +127 -27
- package/tools/cli/lib/config.js +2 -1
- package/tools/cli/lib/ui.js +65 -4
- package/tools/cli/lib/yaml-xml-builder.js +0 -15
- package/tools/schema/agent.js +149 -89
- package/tools/validate-svg-changes.sh +356 -0
- package/custom/src/agents/commit-poet/installation-guide.md +0 -36
- package/custom/src/agents/toolsmith/installation-guide.md +0 -36
- package/src/modules/bmb/docs/workflows/workflow-template.md +0 -152
- package/src/modules/bmb/workflows/create-workflow/steps/step-03-tools-overview.md +0 -127
- package/src/modules/bmb/workflows/create-workflow/steps/step-04-core-tools.md +0 -145
- package/src/modules/bmb/workflows/create-workflow/steps/step-05-memory-requirements.md +0 -136
- package/src/modules/bmb/workflows/create-workflow/steps/step-06-external-tools.md +0 -154
- package/src/modules/bmb/workflows/create-workflow/steps/step-07-installation-guidance.md +0 -159
- package/src/modules/bmb/workflows/create-workflow/steps/step-08-tools-summary.md +0 -167
- package/src/modules/bmb/workflows/create-workflow/steps/step-10-plan-review.md +0 -215
- package/src/modules/bmb/workflows/create-workflow/templates/build-summary.md +0 -36
- package/src/modules/bmb/workflows/create-workflow/templates/completion-section.md +0 -39
- package/src/modules/bmb/workflows/create-workflow/templates/content-template.md +0 -21
- package/src/modules/bmb/workflows/create-workflow/templates/design-section.md +0 -53
- package/src/modules/bmb/workflows/create-workflow/templates/project-info.md +0 -18
- package/src/modules/bmb/workflows/create-workflow/templates/requirements-section.md +0 -47
- package/src/modules/bmb/workflows/create-workflow/templates/review-section.md +0 -56
- package/src/modules/bmb/workflows/create-workflow/templates/workflow-plan.md +0 -54
- package/src/modules/bmb/workflows-legacy/create-module/README.md +0 -229
- package/src/modules/bmb/workflows-legacy/create-module/brainstorm-context.md +0 -137
- package/src/modules/bmb/workflows-legacy/create-module/checklist.md +0 -235
- package/src/modules/bmb/workflows-legacy/create-module/installer-templates/install-config.yaml +0 -92
- package/src/modules/bmb/workflows-legacy/create-module/installer-templates/installer.js +0 -231
- package/src/modules/bmb/workflows-legacy/create-module/instructions.md +0 -577
- package/src/modules/bmb/workflows-legacy/create-module/module-structure.md +0 -400
- package/src/modules/bmb/workflows-legacy/create-module/workflow.yaml +0 -52
- package/src/modules/bmm/workflows/3-solutioning/create-epics-and-stories/epics-template.md +0 -80
- package/src/modules/bmm/workflows/3-solutioning/create-epics-and-stories/instructions.md +0 -387
- package/src/modules/bmm/workflows/3-solutioning/create-epics-and-stories/workflow.yaml +0 -53
- package/src/modules/bmm/workflows/3-solutioning/implementation-readiness/checklist.md +0 -169
- package/src/modules/bmm/workflows/3-solutioning/implementation-readiness/instructions.md +0 -332
- package/src/modules/bmm/workflows/3-solutioning/implementation-readiness/template.md +0 -146
- package/src/modules/bmm/workflows/3-solutioning/implementation-readiness/workflow.yaml +0 -64
- package/tools/cli/commands/agent-install.js +0 -409
- package/tools/cli/commands/cleanup.js +0 -141
- /package/{custom/src → example-custom-content}/agents/commit-poet/commit-poet.agent.yaml +0 -0
- /package/{custom/src → example-custom-content}/agents/toolsmith/toolsmith-sidecar/knowledge/bundlers.md +0 -0
- /package/{custom/src → example-custom-content}/agents/toolsmith/toolsmith-sidecar/knowledge/deploy.md +0 -0
- /package/{custom/src → example-custom-content}/agents/toolsmith/toolsmith-sidecar/knowledge/docs.md +0 -0
- /package/{custom/src → example-custom-content}/agents/toolsmith/toolsmith-sidecar/knowledge/installers.md +0 -0
- /package/{custom/src → example-custom-content}/agents/toolsmith/toolsmith-sidecar/knowledge/modules.md +0 -0
- /package/{custom/src → example-custom-content}/agents/toolsmith/toolsmith-sidecar/knowledge/tests.md +0 -0
|
@@ -1,409 +0,0 @@
|
|
|
1
|
-
const chalk = require('chalk');
|
|
2
|
-
const path = require('node:path');
|
|
3
|
-
const fs = require('node:fs');
|
|
4
|
-
const readline = require('node:readline');
|
|
5
|
-
const {
|
|
6
|
-
findBmadConfig,
|
|
7
|
-
resolvePath,
|
|
8
|
-
discoverAgents,
|
|
9
|
-
loadAgentConfig,
|
|
10
|
-
promptInstallQuestions,
|
|
11
|
-
detectBmadProject,
|
|
12
|
-
addToManifest,
|
|
13
|
-
extractManifestData,
|
|
14
|
-
checkManifestForPath,
|
|
15
|
-
updateManifestEntry,
|
|
16
|
-
saveAgentSource,
|
|
17
|
-
createIdeSlashCommands,
|
|
18
|
-
updateManifestYaml,
|
|
19
|
-
} = require('../lib/agent/installer');
|
|
20
|
-
|
|
21
|
-
module.exports = {
|
|
22
|
-
command: 'agent-install',
|
|
23
|
-
description: 'Install and compile BMAD agents with personalization',
|
|
24
|
-
options: [
|
|
25
|
-
['-s, --source <path>', 'Path to specific agent YAML file or folder'],
|
|
26
|
-
['-d, --defaults', 'Use default values without prompting'],
|
|
27
|
-
['-t, --destination <path>', 'Target installation directory (default: current project BMAD installation)'],
|
|
28
|
-
],
|
|
29
|
-
action: async (options) => {
|
|
30
|
-
try {
|
|
31
|
-
console.log(chalk.cyan('\n🔧 BMAD Agent Installer\n'));
|
|
32
|
-
|
|
33
|
-
// Find BMAD config
|
|
34
|
-
const config = findBmadConfig();
|
|
35
|
-
if (!config) {
|
|
36
|
-
console.log(chalk.yellow('No BMAD installation found in current directory.'));
|
|
37
|
-
console.log(chalk.dim('Looking for .bmad/bmb/config.yaml...'));
|
|
38
|
-
console.log(chalk.red('\nPlease run this command from a project with BMAD installed.'));
|
|
39
|
-
process.exit(1);
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
console.log(chalk.dim(`Found BMAD at: ${config.bmadFolder}`));
|
|
43
|
-
|
|
44
|
-
let selectedAgent = null;
|
|
45
|
-
|
|
46
|
-
// If source provided, use it directly
|
|
47
|
-
if (options.source) {
|
|
48
|
-
const providedPath = path.resolve(options.source);
|
|
49
|
-
|
|
50
|
-
if (!fs.existsSync(providedPath)) {
|
|
51
|
-
console.log(chalk.red(`Path not found: ${providedPath}`));
|
|
52
|
-
process.exit(1);
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
const stat = fs.statSync(providedPath);
|
|
56
|
-
if (stat.isFile() && providedPath.endsWith('.agent.yaml')) {
|
|
57
|
-
selectedAgent = {
|
|
58
|
-
type: 'simple',
|
|
59
|
-
name: path.basename(providedPath, '.agent.yaml'),
|
|
60
|
-
path: providedPath,
|
|
61
|
-
yamlFile: providedPath,
|
|
62
|
-
};
|
|
63
|
-
} else if (stat.isDirectory()) {
|
|
64
|
-
const yamlFiles = fs.readdirSync(providedPath).filter((f) => f.endsWith('.agent.yaml'));
|
|
65
|
-
if (yamlFiles.length === 1) {
|
|
66
|
-
selectedAgent = {
|
|
67
|
-
type: 'expert',
|
|
68
|
-
name: path.basename(providedPath),
|
|
69
|
-
path: providedPath,
|
|
70
|
-
yamlFile: path.join(providedPath, yamlFiles[0]),
|
|
71
|
-
hasSidecar: true,
|
|
72
|
-
};
|
|
73
|
-
} else {
|
|
74
|
-
console.log(chalk.red('Directory must contain exactly one .agent.yaml file'));
|
|
75
|
-
process.exit(1);
|
|
76
|
-
}
|
|
77
|
-
} else {
|
|
78
|
-
console.log(chalk.red('Path must be an .agent.yaml file or a folder containing one'));
|
|
79
|
-
process.exit(1);
|
|
80
|
-
}
|
|
81
|
-
} else {
|
|
82
|
-
// Discover agents from custom location
|
|
83
|
-
const customAgentLocation = config.custom_agent_location
|
|
84
|
-
? resolvePath(config.custom_agent_location, config)
|
|
85
|
-
: path.join(config.bmadFolder, 'custom', 'src', 'agents');
|
|
86
|
-
|
|
87
|
-
console.log(chalk.dim(`Searching for agents in: ${customAgentLocation}\n`));
|
|
88
|
-
|
|
89
|
-
const agents = discoverAgents(customAgentLocation);
|
|
90
|
-
|
|
91
|
-
if (agents.length === 0) {
|
|
92
|
-
console.log(chalk.yellow('No agents found in custom agent location.'));
|
|
93
|
-
console.log(chalk.dim(`Expected location: ${customAgentLocation}`));
|
|
94
|
-
console.log(chalk.dim('\nCreate agents using the BMad Builder workflow or place .agent.yaml files there.'));
|
|
95
|
-
process.exit(0);
|
|
96
|
-
}
|
|
97
|
-
|
|
98
|
-
// List available agents
|
|
99
|
-
console.log(chalk.cyan('Available Agents:\n'));
|
|
100
|
-
for (const [idx, agent] of agents.entries()) {
|
|
101
|
-
const typeIcon = agent.type === 'expert' ? '📚' : '📄';
|
|
102
|
-
console.log(` ${idx + 1}. ${typeIcon} ${chalk.bold(agent.name)} ${chalk.dim(`(${agent.type})`)}`);
|
|
103
|
-
}
|
|
104
|
-
|
|
105
|
-
// Prompt for selection
|
|
106
|
-
const rl = readline.createInterface({
|
|
107
|
-
input: process.stdin,
|
|
108
|
-
output: process.stdout,
|
|
109
|
-
});
|
|
110
|
-
|
|
111
|
-
const selection = await new Promise((resolve) => {
|
|
112
|
-
rl.question('\nSelect agent to install (number): ', resolve);
|
|
113
|
-
});
|
|
114
|
-
rl.close();
|
|
115
|
-
|
|
116
|
-
const selectedIdx = parseInt(selection, 10) - 1;
|
|
117
|
-
if (isNaN(selectedIdx) || selectedIdx < 0 || selectedIdx >= agents.length) {
|
|
118
|
-
console.log(chalk.red('Invalid selection'));
|
|
119
|
-
process.exit(1);
|
|
120
|
-
}
|
|
121
|
-
|
|
122
|
-
selectedAgent = agents[selectedIdx];
|
|
123
|
-
}
|
|
124
|
-
|
|
125
|
-
console.log(chalk.cyan(`\nSelected: ${chalk.bold(selectedAgent.name)}`));
|
|
126
|
-
|
|
127
|
-
// Load agent configuration
|
|
128
|
-
const agentConfig = loadAgentConfig(selectedAgent.yamlFile);
|
|
129
|
-
|
|
130
|
-
if (agentConfig.metadata.name) {
|
|
131
|
-
console.log(chalk.dim(`Agent Name: ${agentConfig.metadata.name}`));
|
|
132
|
-
}
|
|
133
|
-
if (agentConfig.metadata.title) {
|
|
134
|
-
console.log(chalk.dim(`Title: ${agentConfig.metadata.title}`));
|
|
135
|
-
}
|
|
136
|
-
|
|
137
|
-
// Get the agent type (source name)
|
|
138
|
-
const agentType = selectedAgent.name; // e.g., "commit-poet"
|
|
139
|
-
|
|
140
|
-
// Confirm/customize agent persona name
|
|
141
|
-
const rl1 = readline.createInterface({
|
|
142
|
-
input: process.stdin,
|
|
143
|
-
output: process.stdout,
|
|
144
|
-
});
|
|
145
|
-
|
|
146
|
-
const defaultPersonaName = agentConfig.metadata.name || agentType;
|
|
147
|
-
console.log(chalk.cyan('\n📛 Agent Persona Name\n'));
|
|
148
|
-
console.log(chalk.dim(` Agent type: ${agentType}`));
|
|
149
|
-
console.log(chalk.dim(` Default persona: ${defaultPersonaName}`));
|
|
150
|
-
console.log(chalk.dim(' Leave blank to use default, or provide a custom name.'));
|
|
151
|
-
console.log(chalk.dim(' Examples:'));
|
|
152
|
-
console.log(chalk.dim(` - (blank) → "${defaultPersonaName}" as ${agentType}.md`));
|
|
153
|
-
console.log(chalk.dim(` - "Fred" → "Fred" as fred-${agentType}.md`));
|
|
154
|
-
console.log(chalk.dim(` - "Captain Code" → "Captain Code" as captain-code-${agentType}.md`));
|
|
155
|
-
|
|
156
|
-
const customPersonaName = await new Promise((resolve) => {
|
|
157
|
-
rl1.question(`\n Custom name (or Enter for default): `, resolve);
|
|
158
|
-
});
|
|
159
|
-
rl1.close();
|
|
160
|
-
|
|
161
|
-
// Determine final agent file name based on persona name
|
|
162
|
-
let finalAgentName;
|
|
163
|
-
let personaName;
|
|
164
|
-
if (customPersonaName.trim()) {
|
|
165
|
-
personaName = customPersonaName.trim();
|
|
166
|
-
const namePrefix = personaName.toLowerCase().replaceAll(/\s+/g, '-');
|
|
167
|
-
finalAgentName = `${namePrefix}-${agentType}`;
|
|
168
|
-
} else {
|
|
169
|
-
personaName = defaultPersonaName;
|
|
170
|
-
finalAgentName = agentType;
|
|
171
|
-
}
|
|
172
|
-
|
|
173
|
-
console.log(chalk.dim(` Persona: ${personaName}`));
|
|
174
|
-
console.log(chalk.dim(` File: ${finalAgentName}.md`));
|
|
175
|
-
|
|
176
|
-
// Get answers (prompt or use defaults)
|
|
177
|
-
let presetAnswers = {};
|
|
178
|
-
|
|
179
|
-
// If custom persona name provided, inject it as custom_name for template processing
|
|
180
|
-
if (customPersonaName.trim()) {
|
|
181
|
-
presetAnswers.custom_name = personaName;
|
|
182
|
-
}
|
|
183
|
-
|
|
184
|
-
let answers;
|
|
185
|
-
if (agentConfig.installConfig && !options.defaults) {
|
|
186
|
-
answers = await promptInstallQuestions(agentConfig.installConfig, agentConfig.defaults, presetAnswers);
|
|
187
|
-
} else if (agentConfig.installConfig && options.defaults) {
|
|
188
|
-
console.log(chalk.dim('\nUsing default configuration values.'));
|
|
189
|
-
answers = { ...agentConfig.defaults, ...presetAnswers };
|
|
190
|
-
} else {
|
|
191
|
-
answers = { ...agentConfig.defaults, ...presetAnswers };
|
|
192
|
-
}
|
|
193
|
-
|
|
194
|
-
// Determine target directory
|
|
195
|
-
let targetDir = options.destination ? path.resolve(options.destination) : null;
|
|
196
|
-
|
|
197
|
-
// If no target specified, prompt for it
|
|
198
|
-
if (targetDir) {
|
|
199
|
-
// If target provided via --destination, check if it's a project root and adjust
|
|
200
|
-
const otherProject = detectBmadProject(targetDir);
|
|
201
|
-
if (otherProject && !targetDir.includes('agents')) {
|
|
202
|
-
// User specified project root, redirect to custom agents folder
|
|
203
|
-
targetDir = path.join(otherProject.bmadFolder, 'custom', 'agents');
|
|
204
|
-
console.log(chalk.dim(` Auto-selecting custom agents folder: ${targetDir}`));
|
|
205
|
-
}
|
|
206
|
-
} else {
|
|
207
|
-
const rl = readline.createInterface({
|
|
208
|
-
input: process.stdin,
|
|
209
|
-
output: process.stdout,
|
|
210
|
-
});
|
|
211
|
-
|
|
212
|
-
console.log(chalk.cyan('\n📂 Installation Target\n'));
|
|
213
|
-
|
|
214
|
-
// Option 1: Current project's custom agents folder
|
|
215
|
-
const currentCustom = path.join(config.bmadFolder, 'custom', 'agents');
|
|
216
|
-
console.log(` 1. Current project: ${chalk.dim(currentCustom)}`);
|
|
217
|
-
|
|
218
|
-
// Option 2: Specify another project path
|
|
219
|
-
console.log(` 2. Another project (enter path)`);
|
|
220
|
-
|
|
221
|
-
const choice = await new Promise((resolve) => {
|
|
222
|
-
rl.question('\n Select option (1 or path): ', resolve);
|
|
223
|
-
});
|
|
224
|
-
|
|
225
|
-
if (choice.trim() === '1' || choice.trim() === '') {
|
|
226
|
-
targetDir = currentCustom;
|
|
227
|
-
} else if (choice.trim() === '2') {
|
|
228
|
-
const projectPath = await new Promise((resolve) => {
|
|
229
|
-
rl.question(' Project path: ', resolve);
|
|
230
|
-
});
|
|
231
|
-
|
|
232
|
-
// Detect if it's a BMAD project and use its custom folder
|
|
233
|
-
const otherProject = detectBmadProject(path.resolve(projectPath));
|
|
234
|
-
if (otherProject) {
|
|
235
|
-
targetDir = path.join(otherProject.bmadFolder, 'custom', 'agents');
|
|
236
|
-
console.log(chalk.dim(` Found BMAD project, using: ${targetDir}`));
|
|
237
|
-
} else {
|
|
238
|
-
targetDir = path.resolve(projectPath);
|
|
239
|
-
}
|
|
240
|
-
} else {
|
|
241
|
-
// User entered a path directly
|
|
242
|
-
const otherProject = detectBmadProject(path.resolve(choice));
|
|
243
|
-
if (otherProject) {
|
|
244
|
-
targetDir = path.join(otherProject.bmadFolder, 'custom', 'agents');
|
|
245
|
-
console.log(chalk.dim(` Found BMAD project, using: ${targetDir}`));
|
|
246
|
-
} else {
|
|
247
|
-
targetDir = path.resolve(choice);
|
|
248
|
-
}
|
|
249
|
-
}
|
|
250
|
-
|
|
251
|
-
rl.close();
|
|
252
|
-
}
|
|
253
|
-
|
|
254
|
-
if (!fs.existsSync(targetDir)) {
|
|
255
|
-
fs.mkdirSync(targetDir, { recursive: true });
|
|
256
|
-
}
|
|
257
|
-
|
|
258
|
-
console.log(chalk.dim(`\nInstalling to: ${targetDir}`));
|
|
259
|
-
|
|
260
|
-
// Detect if target is within a BMAD project
|
|
261
|
-
const targetProject = detectBmadProject(targetDir);
|
|
262
|
-
if (targetProject) {
|
|
263
|
-
console.log(chalk.cyan(` Detected BMAD project at: ${targetProject.projectRoot}`));
|
|
264
|
-
}
|
|
265
|
-
|
|
266
|
-
// Check for duplicate in manifest by path (not by type)
|
|
267
|
-
let shouldUpdateExisting = false;
|
|
268
|
-
let existingEntry = null;
|
|
269
|
-
|
|
270
|
-
if (targetProject) {
|
|
271
|
-
// Check if this exact installed name already exists
|
|
272
|
-
const expectedPath = `.bmad/custom/agents/${finalAgentName}/${finalAgentName}.md`;
|
|
273
|
-
existingEntry = checkManifestForPath(targetProject.manifestFile, expectedPath);
|
|
274
|
-
|
|
275
|
-
if (existingEntry) {
|
|
276
|
-
const rl2 = readline.createInterface({
|
|
277
|
-
input: process.stdin,
|
|
278
|
-
output: process.stdout,
|
|
279
|
-
});
|
|
280
|
-
|
|
281
|
-
console.log(chalk.yellow(`\n⚠️ Agent "${finalAgentName}" already installed`));
|
|
282
|
-
console.log(chalk.dim(` Type: ${agentType}`));
|
|
283
|
-
console.log(chalk.dim(` Path: ${existingEntry.path}`));
|
|
284
|
-
|
|
285
|
-
const overwrite = await new Promise((resolve) => {
|
|
286
|
-
rl2.question(' Overwrite existing installation? [Y/n]: ', resolve);
|
|
287
|
-
});
|
|
288
|
-
rl2.close();
|
|
289
|
-
|
|
290
|
-
if (overwrite.toLowerCase() === 'n') {
|
|
291
|
-
console.log(chalk.yellow('Installation cancelled.'));
|
|
292
|
-
process.exit(0);
|
|
293
|
-
}
|
|
294
|
-
|
|
295
|
-
shouldUpdateExisting = true;
|
|
296
|
-
}
|
|
297
|
-
}
|
|
298
|
-
|
|
299
|
-
// Install the agent with custom name
|
|
300
|
-
// Override the folder name with finalAgentName
|
|
301
|
-
const agentTargetDir = path.join(targetDir, finalAgentName);
|
|
302
|
-
|
|
303
|
-
if (!fs.existsSync(agentTargetDir)) {
|
|
304
|
-
fs.mkdirSync(agentTargetDir, { recursive: true });
|
|
305
|
-
}
|
|
306
|
-
|
|
307
|
-
// Compile and install
|
|
308
|
-
const { compileAgent } = require('../lib/agent/compiler');
|
|
309
|
-
|
|
310
|
-
// Calculate target path for agent ID
|
|
311
|
-
const projectRoot = targetProject ? targetProject.projectRoot : config.projectRoot;
|
|
312
|
-
const compiledFileName = `${finalAgentName}.md`;
|
|
313
|
-
const compiledPath = path.join(agentTargetDir, compiledFileName);
|
|
314
|
-
const relativePath = path.relative(projectRoot, compiledPath);
|
|
315
|
-
|
|
316
|
-
// Compile with proper name and path
|
|
317
|
-
const { xml, metadata, processedYaml } = compileAgent(
|
|
318
|
-
fs.readFileSync(selectedAgent.yamlFile, 'utf8'),
|
|
319
|
-
answers,
|
|
320
|
-
finalAgentName,
|
|
321
|
-
relativePath,
|
|
322
|
-
);
|
|
323
|
-
|
|
324
|
-
// Write compiled XML (.md) with custom name
|
|
325
|
-
fs.writeFileSync(compiledPath, xml, 'utf8');
|
|
326
|
-
|
|
327
|
-
const result = {
|
|
328
|
-
success: true,
|
|
329
|
-
agentName: finalAgentName,
|
|
330
|
-
targetDir: agentTargetDir,
|
|
331
|
-
compiledFile: compiledPath,
|
|
332
|
-
sidecarCopied: false,
|
|
333
|
-
};
|
|
334
|
-
|
|
335
|
-
// Copy sidecar files for expert agents
|
|
336
|
-
if (selectedAgent.hasSidecar && selectedAgent.type === 'expert') {
|
|
337
|
-
const { copySidecarFiles } = require('../lib/agent/installer');
|
|
338
|
-
const sidecarFiles = copySidecarFiles(selectedAgent.path, agentTargetDir, selectedAgent.yamlFile);
|
|
339
|
-
result.sidecarCopied = true;
|
|
340
|
-
result.sidecarFiles = sidecarFiles;
|
|
341
|
-
}
|
|
342
|
-
|
|
343
|
-
console.log(chalk.green('\n✨ Agent installed successfully!'));
|
|
344
|
-
console.log(chalk.cyan(` Name: ${result.agentName}`));
|
|
345
|
-
console.log(chalk.cyan(` Location: ${result.targetDir}`));
|
|
346
|
-
console.log(chalk.cyan(` Compiled: ${path.basename(result.compiledFile)}`));
|
|
347
|
-
|
|
348
|
-
if (result.sidecarCopied) {
|
|
349
|
-
console.log(chalk.cyan(` Sidecar files: ${result.sidecarFiles.length} files copied`));
|
|
350
|
-
}
|
|
351
|
-
|
|
352
|
-
// Save source YAML to _cfg/custom/agents/ and register in manifest
|
|
353
|
-
if (targetProject) {
|
|
354
|
-
// Save source for reinstallation with embedded answers
|
|
355
|
-
console.log(chalk.dim(`\nSaving source to: ${targetProject.cfgFolder}/custom/agents/`));
|
|
356
|
-
saveAgentSource(selectedAgent, targetProject.cfgFolder, finalAgentName, answers);
|
|
357
|
-
console.log(chalk.green(` ✓ Source saved for reinstallation`));
|
|
358
|
-
|
|
359
|
-
// Register/update in manifest
|
|
360
|
-
console.log(chalk.dim(`Registering in manifest: ${targetProject.manifestFile}`));
|
|
361
|
-
|
|
362
|
-
const manifestData = extractManifestData(xml, { ...metadata, name: finalAgentName }, relativePath, 'custom');
|
|
363
|
-
// Use finalAgentName as the manifest name field (unique identifier)
|
|
364
|
-
manifestData.name = finalAgentName;
|
|
365
|
-
// Use compiled metadata.name (persona name after template processing), not source agentConfig
|
|
366
|
-
manifestData.displayName = metadata.name || agentType;
|
|
367
|
-
// Store the actual installed path/name
|
|
368
|
-
manifestData.path = relativePath;
|
|
369
|
-
|
|
370
|
-
if (shouldUpdateExisting && existingEntry) {
|
|
371
|
-
updateManifestEntry(targetProject.manifestFile, manifestData, existingEntry._lineNumber);
|
|
372
|
-
console.log(chalk.green(` ✓ Updated existing entry in agent-manifest.csv`));
|
|
373
|
-
} else {
|
|
374
|
-
addToManifest(targetProject.manifestFile, manifestData);
|
|
375
|
-
console.log(chalk.green(` ✓ Added to agent-manifest.csv`));
|
|
376
|
-
}
|
|
377
|
-
|
|
378
|
-
// Create IDE slash commands
|
|
379
|
-
const ideResults = await createIdeSlashCommands(targetProject.projectRoot, finalAgentName, relativePath, metadata);
|
|
380
|
-
if (Object.keys(ideResults).length > 0) {
|
|
381
|
-
console.log(chalk.green(` ✓ Created IDE commands:`));
|
|
382
|
-
for (const [ideName, result] of Object.entries(ideResults)) {
|
|
383
|
-
console.log(chalk.dim(` ${ideName}: ${result.command}`));
|
|
384
|
-
}
|
|
385
|
-
}
|
|
386
|
-
|
|
387
|
-
// Update manifest.yaml with custom_agents tracking
|
|
388
|
-
const manifestYamlPath = path.join(targetProject.cfgFolder, 'manifest.yaml');
|
|
389
|
-
if (updateManifestYaml(manifestYamlPath, finalAgentName, agentType)) {
|
|
390
|
-
console.log(chalk.green(` ✓ Updated manifest.yaml custom_agents`));
|
|
391
|
-
}
|
|
392
|
-
}
|
|
393
|
-
|
|
394
|
-
console.log(chalk.dim(`\nAgent ID: ${relativePath}`));
|
|
395
|
-
|
|
396
|
-
if (targetProject) {
|
|
397
|
-
console.log(chalk.yellow('\nAgent is now registered and available in the target project!'));
|
|
398
|
-
} else {
|
|
399
|
-
console.log(chalk.yellow('\nTo use this agent, reference it in your manifest or load it directly.'));
|
|
400
|
-
}
|
|
401
|
-
|
|
402
|
-
process.exit(0);
|
|
403
|
-
} catch (error) {
|
|
404
|
-
console.error(chalk.red('Agent installation failed:'), error.message);
|
|
405
|
-
console.error(chalk.dim(error.stack));
|
|
406
|
-
process.exit(1);
|
|
407
|
-
}
|
|
408
|
-
},
|
|
409
|
-
};
|
|
@@ -1,141 +0,0 @@
|
|
|
1
|
-
const chalk = require('chalk');
|
|
2
|
-
const nodePath = require('node:path');
|
|
3
|
-
const { Installer } = require('../installers/lib/core/installer');
|
|
4
|
-
|
|
5
|
-
module.exports = {
|
|
6
|
-
command: 'cleanup',
|
|
7
|
-
description: 'Clean up obsolete files from BMAD installation',
|
|
8
|
-
options: [
|
|
9
|
-
['-d, --dry-run', 'Show what would be deleted without actually deleting'],
|
|
10
|
-
['-a, --auto-delete', 'Automatically delete non-retained files without prompts'],
|
|
11
|
-
['-l, --list-retained', 'List currently retained files'],
|
|
12
|
-
['-c, --clear-retained', 'Clear retained files list'],
|
|
13
|
-
],
|
|
14
|
-
action: async (options) => {
|
|
15
|
-
try {
|
|
16
|
-
// Create installer and let it find the BMAD directory
|
|
17
|
-
const installer = new Installer();
|
|
18
|
-
const bmadDir = await installer.findBmadDir(process.cwd());
|
|
19
|
-
|
|
20
|
-
if (!bmadDir) {
|
|
21
|
-
console.error(chalk.red('❌ BMAD installation not found'));
|
|
22
|
-
process.exit(1);
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
const retentionPath = nodePath.join(bmadDir, '_cfg', 'user-retained-files.yaml');
|
|
26
|
-
|
|
27
|
-
// Handle list-retained option
|
|
28
|
-
if (options.listRetained) {
|
|
29
|
-
const fs = require('fs-extra');
|
|
30
|
-
const yaml = require('js-yaml');
|
|
31
|
-
|
|
32
|
-
if (await fs.pathExists(retentionPath)) {
|
|
33
|
-
const retentionContent = await fs.readFile(retentionPath, 'utf8');
|
|
34
|
-
const retentionData = yaml.load(retentionContent) || { retainedFiles: [] };
|
|
35
|
-
|
|
36
|
-
if (retentionData.retainedFiles.length > 0) {
|
|
37
|
-
console.log(chalk.cyan('\n📋 Retained Files:\n'));
|
|
38
|
-
for (const file of retentionData.retainedFiles) {
|
|
39
|
-
console.log(chalk.dim(` - ${file}`));
|
|
40
|
-
}
|
|
41
|
-
console.log();
|
|
42
|
-
} else {
|
|
43
|
-
console.log(chalk.yellow('\n✨ No retained files found\n'));
|
|
44
|
-
}
|
|
45
|
-
} else {
|
|
46
|
-
console.log(chalk.yellow('\n✨ No retained files found\n'));
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
return;
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
// Handle clear-retained option
|
|
53
|
-
if (options.clearRetained) {
|
|
54
|
-
const fs = require('fs-extra');
|
|
55
|
-
|
|
56
|
-
if (await fs.pathExists(retentionPath)) {
|
|
57
|
-
await fs.remove(retentionPath);
|
|
58
|
-
console.log(chalk.green('\n✅ Cleared retained files list\n'));
|
|
59
|
-
} else {
|
|
60
|
-
console.log(chalk.yellow('\n✨ No retained files list to clear\n'));
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
return;
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
// Handle cleanup operations
|
|
67
|
-
if (options.dryRun) {
|
|
68
|
-
console.log(chalk.cyan('\n🔍 Legacy File Scan (Dry Run)\n'));
|
|
69
|
-
|
|
70
|
-
const legacyFiles = await installer.scanForLegacyFiles(bmadDir);
|
|
71
|
-
const allLegacyFiles = [
|
|
72
|
-
...legacyFiles.backup,
|
|
73
|
-
...legacyFiles.documentation,
|
|
74
|
-
...legacyFiles.deprecated_task,
|
|
75
|
-
...legacyFiles.unknown,
|
|
76
|
-
];
|
|
77
|
-
|
|
78
|
-
if (allLegacyFiles.length === 0) {
|
|
79
|
-
console.log(chalk.green('✨ No legacy files found\n'));
|
|
80
|
-
return;
|
|
81
|
-
}
|
|
82
|
-
|
|
83
|
-
// Group files by category
|
|
84
|
-
const categories = [];
|
|
85
|
-
if (legacyFiles.backup.length > 0) {
|
|
86
|
-
categories.push({ name: 'Backup Files (.bak)', files: legacyFiles.backup });
|
|
87
|
-
}
|
|
88
|
-
if (legacyFiles.documentation.length > 0) {
|
|
89
|
-
categories.push({ name: 'Documentation', files: legacyFiles.documentation });
|
|
90
|
-
}
|
|
91
|
-
if (legacyFiles.deprecated_task.length > 0) {
|
|
92
|
-
categories.push({ name: 'Deprecated Task Files', files: legacyFiles.deprecated_task });
|
|
93
|
-
}
|
|
94
|
-
if (legacyFiles.unknown.length > 0) {
|
|
95
|
-
categories.push({ name: 'Unknown Files', files: legacyFiles.unknown });
|
|
96
|
-
}
|
|
97
|
-
|
|
98
|
-
for (const category of categories) {
|
|
99
|
-
console.log(chalk.yellow(`${category.name}:`));
|
|
100
|
-
for (const file of category.files) {
|
|
101
|
-
const size = (file.size / 1024).toFixed(1);
|
|
102
|
-
const date = file.mtime.toLocaleDateString();
|
|
103
|
-
let line = ` - ${file.relativePath} (${size}KB, ${date})`;
|
|
104
|
-
if (file.suggestedAlternative) {
|
|
105
|
-
line += chalk.dim(` → ${file.suggestedAlternative}`);
|
|
106
|
-
}
|
|
107
|
-
console.log(chalk.dim(line));
|
|
108
|
-
}
|
|
109
|
-
console.log();
|
|
110
|
-
}
|
|
111
|
-
|
|
112
|
-
console.log(chalk.cyan(`Found ${allLegacyFiles.length} legacy file(s) that could be cleaned up.\n`));
|
|
113
|
-
console.log(chalk.dim('Run "bmad cleanup" to actually delete these files.\n'));
|
|
114
|
-
|
|
115
|
-
return;
|
|
116
|
-
}
|
|
117
|
-
|
|
118
|
-
// Perform actual cleanup
|
|
119
|
-
console.log(chalk.cyan('\n🧹 Cleaning up legacy files...\n'));
|
|
120
|
-
|
|
121
|
-
const result = await installer.performCleanup(bmadDir, options.autoDelete);
|
|
122
|
-
|
|
123
|
-
if (result.message) {
|
|
124
|
-
console.log(chalk.dim(result.message));
|
|
125
|
-
} else {
|
|
126
|
-
if (result.deleted > 0) {
|
|
127
|
-
console.log(chalk.green(`✅ Deleted ${result.deleted} legacy file(s)`));
|
|
128
|
-
}
|
|
129
|
-
if (result.retained > 0) {
|
|
130
|
-
console.log(chalk.yellow(`⏭️ Retained ${result.retained} file(s)`));
|
|
131
|
-
console.log(chalk.dim('Run "bmad cleanup --list-retained" to see retained files\n'));
|
|
132
|
-
}
|
|
133
|
-
}
|
|
134
|
-
|
|
135
|
-
console.log();
|
|
136
|
-
} catch (error) {
|
|
137
|
-
console.error(chalk.red(`❌ Error: ${error.message}`));
|
|
138
|
-
process.exit(1);
|
|
139
|
-
}
|
|
140
|
-
},
|
|
141
|
-
};
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
/package/{custom/src → example-custom-content}/agents/toolsmith/toolsmith-sidecar/knowledge/docs.md
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
/package/{custom/src → example-custom-content}/agents/toolsmith/toolsmith-sidecar/knowledge/tests.md
RENAMED
|
File without changes
|