Compare commits
13 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
8211d2daff | ||
|
|
1676f5189e | ||
|
|
3c3d58939f | ||
|
|
2d954d3481 | ||
|
|
f7c2a4fb6c | ||
|
|
9df28d5313 | ||
|
|
2cf322ee0d | ||
|
|
5dc4043577 | ||
|
|
a72b790f3b | ||
|
|
55f834954f | ||
|
|
dcebe91d5e | ||
|
|
ce5b37b628 | ||
|
|
c079c28dc4 |
34
CHANGELOG.md
34
CHANGELOG.md
@@ -1,9 +1,39 @@
|
||||
## [4.33.1](https://github.com/bmadcode/BMAD-METHOD/compare/v4.33.0...v4.33.1) (2025-07-29)
|
||||
## [4.35.3](https://github.com/bmadcode/BMAD-METHOD/compare/v4.35.2...v4.35.3) (2025-08-06)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* dev agent yaml syntax for develop-story command ([#362](https://github.com/bmadcode/BMAD-METHOD/issues/362)) ([bcb3728](https://github.com/bmadcode/BMAD-METHOD/commit/bcb3728f8868c0f83bca3d61fbd7e15c4e114526))
|
||||
* doc location improvement ([1676f51](https://github.com/bmadcode/BMAD-METHOD/commit/1676f5189ed057fa2d7facbd6a771fe67cdb6372))
|
||||
|
||||
## [4.35.2](https://github.com/bmadcode/BMAD-METHOD/compare/v4.35.1...v4.35.2) (2025-08-06)
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
- npx status check ([f7c2a4f](https://github.com/bmadcode/BMAD-METHOD/commit/f7c2a4fb6c454b17d250b85537129b01ffee6b85))
|
||||
|
||||
## [4.35.1](https://github.com/bmadcode/BMAD-METHOD/compare/v4.35.0...v4.35.1) (2025-08-06)
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
- npx hanging commands ([2cf322e](https://github.com/bmadcode/BMAD-METHOD/commit/2cf322ee0d9b563a4998c72b2c5eab259594739b))
|
||||
|
||||
# [4.35.0](https://github.com/bmadcode/BMAD-METHOD/compare/v4.34.0...v4.35.0) (2025-08-04)
|
||||
|
||||
### Features
|
||||
|
||||
- add qwen-code ide support to bmad installer. ([#392](https://github.com/bmadcode/BMAD-METHOD/issues/392)) ([a72b790](https://github.com/bmadcode/BMAD-METHOD/commit/a72b790f3be6c77355511ace2d63e6bec4d751f1))
|
||||
|
||||
# [4.34.0](https://github.com/bmadcode/BMAD-METHOD/compare/v4.33.1...v4.34.0) (2025-08-03)
|
||||
|
||||
### Features
|
||||
|
||||
- add KiloCode integration support to BMAD installer ([#390](https://github.com/bmadcode/BMAD-METHOD/issues/390)) ([dcebe91](https://github.com/bmadcode/BMAD-METHOD/commit/dcebe91d5ea68e69aa27183411a81639d444efd7))
|
||||
|
||||
## [4.33.1](https://github.com/bmadcode/BMAD-METHOD/compare/v4.33.0...v4.33.1) (2025-07-29)
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
- dev agent yaml syntax for develop-story command ([#362](https://github.com/bmadcode/BMAD-METHOD/issues/362)) ([bcb3728](https://github.com/bmadcode/BMAD-METHOD/commit/bcb3728f8868c0f83bca3d61fbd7e15c4e114526))
|
||||
|
||||
# [4.33.0](https://github.com/bmadcode/BMAD-METHOD/compare/v4.32.0...v4.33.0) (2025-07-28)
|
||||
|
||||
|
||||
14
README.md
14
README.md
@@ -23,7 +23,7 @@ Foundations in Agentic Agile Driven Development, known as the Breakthrough Metho
|
||||
|
||||
This two-phase approach eliminates both **planning inconsistency** and **context loss** - the biggest problems in AI-assisted development. Your Dev agent opens a story file with complete understanding of what to build, how to build it, and why.
|
||||
|
||||
**📖 [See the complete workflow in the User Guide](bmad-core/user-guide.md)** - Planning phase, development cycle, and all agent roles
|
||||
**📖 [See the complete workflow in the User Guide](docs/user-guide.md)** - Planning phase, development cycle, and all agent roles
|
||||
|
||||
## Quick Navigation
|
||||
|
||||
@@ -31,16 +31,16 @@ This two-phase approach eliminates both **planning inconsistency** and **context
|
||||
|
||||
**Before diving in, review these critical workflow diagrams that explain how BMad works:**
|
||||
|
||||
1. **[Planning Workflow (Web UI)](bmad-core/user-guide.md#the-planning-workflow-web-ui)** - How to create PRD and Architecture documents
|
||||
2. **[Core Development Cycle (IDE)](bmad-core/user-guide.md#the-core-development-cycle-ide)** - How SM, Dev, and QA agents collaborate through story files
|
||||
1. **[Planning Workflow (Web UI)](docs/user-guide.md#the-planning-workflow-web-ui)** - How to create PRD and Architecture documents
|
||||
2. **[Core Development Cycle (IDE)](docs/user-guide.md#the-core-development-cycle-ide)** - How SM, Dev, and QA agents collaborate through story files
|
||||
|
||||
> ⚠️ **These diagrams explain 90% of BMad Method Agentic Agile flow confusion** - Understanding the PRD+Architecture creation and the SM/Dev/QA workflow and how agents pass notes through story files is essential - and also explains why this is NOT taskmaster or just a simple task runner!
|
||||
|
||||
### What would you like to do?
|
||||
|
||||
- **[Install and Build software with Full Stack Agile AI Team](#quick-start)** → Quick Start Instruction
|
||||
- **[Learn how to use BMad](bmad-core/user-guide.md)** → Complete user guide and walkthrough
|
||||
- **[See available AI agents](#available-agents)** → Specialized roles for your team
|
||||
- **[Learn how to use BMad](docs/user-guide.md)** → Complete user guide and walkthrough
|
||||
- **[See available AI agents](/bmad-core/agents))** → Specialized roles for your team
|
||||
- **[Explore non-technical uses](#-beyond-software-development---expansion-packs)** → Creative writing, business, wellness, education
|
||||
- **[Create my own AI agents](#creating-your-own-expansion-pack)** → Build agents for your domain
|
||||
- **[Browse ready-made expansion packs](expansion-packs/)** → Game dev, DevOps, infrastructure and get inspired with ideas and examples
|
||||
@@ -97,7 +97,7 @@ This single command handles:
|
||||
3. **Upload & configure**: Upload the file and set instructions: "Your critical operating instructions are attached, do not break character as directed"
|
||||
4. **Start Ideating and Planning**: Start chatting! Type `*help` to see available commands or pick an agent like `*analyst` to start right in on creating a brief.
|
||||
5. **CRITICAL**: Talk to BMad Orchestrator in the web at ANY TIME (#bmad-orchestrator command) and ask it questions about how this all works!
|
||||
6. **When to move to the IDE**: Once you have your PRD, Architecture, optional UX and Briefs - its time to switch over to the IDE to shard your docs, and start implementing the actual code! See the [User guide](bmad-core/user-guide.md) for more details
|
||||
6. **When to move to the IDE**: Once you have your PRD, Architecture, optional UX and Briefs - its time to switch over to the IDE to shard your docs, and start implementing the actual code! See the [User guide](docs/user-guide.md) for more details
|
||||
|
||||
### Alternative: Clone and Build
|
||||
|
||||
@@ -161,7 +161,7 @@ The generated XML file contains all your project's source code in a structured f
|
||||
|
||||
### Essential Guides
|
||||
|
||||
- 📖 **[User Guide](bmad-core/user-guide.md)** - Complete walkthrough from project inception to completion
|
||||
- 📖 **[User Guide](docs/user-guide.md)** - Complete walkthrough from project inception to completion
|
||||
- 🏗️ **[Core Architecture](docs/core-architecture.md)** - Technical deep dive and system design
|
||||
- 🚀 **[Expansion Packs Guide](docs/expansion-packs.md)** - Extend BMad to any domain beyond software development
|
||||
|
||||
|
||||
18
dist/agents/dev.txt
vendored
18
dist/agents/dev.txt
vendored
@@ -72,15 +72,15 @@ commands:
|
||||
- run-tests: Execute linting and tests
|
||||
- explain: teach me what and why you did whatever you just did in detail so I can learn. Explain to me as if you were training a junior engineer.
|
||||
- exit: Say goodbye as the Developer, and then abandon inhabiting this persona
|
||||
develop-story:
|
||||
order-of-execution: Read (first or next) task→Implement Task and its subtasks→Write tests→Execute validations→Only if ALL pass, then update the task checkbox with [x]→Update story section File List to ensure it lists and new or modified or deleted source file→repeat order-of-execution until complete
|
||||
story-file-updates-ONLY:
|
||||
- CRITICAL: ONLY UPDATE THE STORY FILE WITH UPDATES TO SECTIONS INDICATED BELOW. DO NOT MODIFY ANY OTHER SECTIONS.
|
||||
- CRITICAL: You are ONLY authorized to edit these specific sections of story files - Tasks / Subtasks Checkboxes, Dev Agent Record section and all its subsections, Agent Model Used, Debug Log References, Completion Notes List, File List, Change Log, Status
|
||||
- CRITICAL: DO NOT modify Status, Story, Acceptance Criteria, Dev Notes, Testing sections, or any other sections not listed above
|
||||
blocking: 'HALT for: Unapproved deps needed, confirm with user | Ambiguous after story check | 3 failures attempting to implement or fix something repeatedly | Missing config | Failing regression'
|
||||
ready-for-review: Code matches requirements + All validations pass + Follows standards + File List complete
|
||||
completion: 'All Tasks and Subtasks marked [x] and have tests→Validations and full regression passes (DON''T BE LAZY, EXECUTE ALL TESTS and CONFIRM)→Ensure File List is Complete→run the task execute-checklist for the checklist story-dod-checklist→set story status: ''Ready for Review''→HALT'
|
||||
- develop-story:
|
||||
- order-of-execution: Read (first or next) task→Implement Task and its subtasks→Write tests→Execute validations→Only if ALL pass, then update the task checkbox with [x]→Update story section File List to ensure it lists and new or modified or deleted source file→repeat order-of-execution until complete
|
||||
- story-file-updates-ONLY:
|
||||
- CRITICAL: ONLY UPDATE THE STORY FILE WITH UPDATES TO SECTIONS INDICATED BELOW. DO NOT MODIFY ANY OTHER SECTIONS.
|
||||
- CRITICAL: You are ONLY authorized to edit these specific sections of story files - Tasks / Subtasks Checkboxes, Dev Agent Record section and all its subsections, Agent Model Used, Debug Log References, Completion Notes List, File List, Change Log, Status
|
||||
- CRITICAL: DO NOT modify Status, Story, Acceptance Criteria, Dev Notes, Testing sections, or any other sections not listed above
|
||||
- blocking: 'HALT for: Unapproved deps needed, confirm with user | Ambiguous after story check | 3 failures attempting to implement or fix something repeatedly | Missing config | Failing regression'
|
||||
- ready-for-review: Code matches requirements + All validations pass + Follows standards + File List complete
|
||||
- completion: 'All Tasks and Subtasks marked [x] and have tests→Validations and full regression passes (DON''T BE LAZY, EXECUTE ALL TESTS and CONFIRM)→Ensure File List is Complete→run the task execute-checklist for the checklist story-dod-checklist→set story status: ''Ready for Review''→HALT'
|
||||
dependencies:
|
||||
tasks:
|
||||
- execute-checklist.md
|
||||
|
||||
18
dist/teams/team-all.txt
vendored
18
dist/teams/team-all.txt
vendored
@@ -352,15 +352,15 @@ commands:
|
||||
- run-tests: Execute linting and tests
|
||||
- explain: teach me what and why you did whatever you just did in detail so I can learn. Explain to me as if you were training a junior engineer.
|
||||
- exit: Say goodbye as the Developer, and then abandon inhabiting this persona
|
||||
develop-story:
|
||||
order-of-execution: Read (first or next) task→Implement Task and its subtasks→Write tests→Execute validations→Only if ALL pass, then update the task checkbox with [x]→Update story section File List to ensure it lists and new or modified or deleted source file→repeat order-of-execution until complete
|
||||
story-file-updates-ONLY:
|
||||
- CRITICAL: ONLY UPDATE THE STORY FILE WITH UPDATES TO SECTIONS INDICATED BELOW. DO NOT MODIFY ANY OTHER SECTIONS.
|
||||
- CRITICAL: You are ONLY authorized to edit these specific sections of story files - Tasks / Subtasks Checkboxes, Dev Agent Record section and all its subsections, Agent Model Used, Debug Log References, Completion Notes List, File List, Change Log, Status
|
||||
- CRITICAL: DO NOT modify Status, Story, Acceptance Criteria, Dev Notes, Testing sections, or any other sections not listed above
|
||||
blocking: 'HALT for: Unapproved deps needed, confirm with user | Ambiguous after story check | 3 failures attempting to implement or fix something repeatedly | Missing config | Failing regression'
|
||||
ready-for-review: Code matches requirements + All validations pass + Follows standards + File List complete
|
||||
completion: 'All Tasks and Subtasks marked [x] and have tests→Validations and full regression passes (DON''T BE LAZY, EXECUTE ALL TESTS and CONFIRM)→Ensure File List is Complete→run the task execute-checklist for the checklist story-dod-checklist→set story status: ''Ready for Review''→HALT'
|
||||
- develop-story:
|
||||
- order-of-execution: Read (first or next) task→Implement Task and its subtasks→Write tests→Execute validations→Only if ALL pass, then update the task checkbox with [x]→Update story section File List to ensure it lists and new or modified or deleted source file→repeat order-of-execution until complete
|
||||
- story-file-updates-ONLY:
|
||||
- CRITICAL: ONLY UPDATE THE STORY FILE WITH UPDATES TO SECTIONS INDICATED BELOW. DO NOT MODIFY ANY OTHER SECTIONS.
|
||||
- CRITICAL: You are ONLY authorized to edit these specific sections of story files - Tasks / Subtasks Checkboxes, Dev Agent Record section and all its subsections, Agent Model Used, Debug Log References, Completion Notes List, File List, Change Log, Status
|
||||
- CRITICAL: DO NOT modify Status, Story, Acceptance Criteria, Dev Notes, Testing sections, or any other sections not listed above
|
||||
- blocking: 'HALT for: Unapproved deps needed, confirm with user | Ambiguous after story check | 3 failures attempting to implement or fix something repeatedly | Missing config | Failing regression'
|
||||
- ready-for-review: Code matches requirements + All validations pass + Follows standards + File List complete
|
||||
- completion: 'All Tasks and Subtasks marked [x] and have tests→Validations and full regression passes (DON''T BE LAZY, EXECUTE ALL TESTS and CONFIRM)→Ensure File List is Complete→run the task execute-checklist for the checklist story-dod-checklist→set story status: ''Ready for Review''→HALT'
|
||||
dependencies:
|
||||
tasks:
|
||||
- execute-checklist.md
|
||||
|
||||
18
dist/teams/team-ide-minimal.txt
vendored
18
dist/teams/team-ide-minimal.txt
vendored
@@ -322,15 +322,15 @@ commands:
|
||||
- run-tests: Execute linting and tests
|
||||
- explain: teach me what and why you did whatever you just did in detail so I can learn. Explain to me as if you were training a junior engineer.
|
||||
- exit: Say goodbye as the Developer, and then abandon inhabiting this persona
|
||||
develop-story:
|
||||
order-of-execution: Read (first or next) task→Implement Task and its subtasks→Write tests→Execute validations→Only if ALL pass, then update the task checkbox with [x]→Update story section File List to ensure it lists and new or modified or deleted source file→repeat order-of-execution until complete
|
||||
story-file-updates-ONLY:
|
||||
- CRITICAL: ONLY UPDATE THE STORY FILE WITH UPDATES TO SECTIONS INDICATED BELOW. DO NOT MODIFY ANY OTHER SECTIONS.
|
||||
- CRITICAL: You are ONLY authorized to edit these specific sections of story files - Tasks / Subtasks Checkboxes, Dev Agent Record section and all its subsections, Agent Model Used, Debug Log References, Completion Notes List, File List, Change Log, Status
|
||||
- CRITICAL: DO NOT modify Status, Story, Acceptance Criteria, Dev Notes, Testing sections, or any other sections not listed above
|
||||
blocking: 'HALT for: Unapproved deps needed, confirm with user | Ambiguous after story check | 3 failures attempting to implement or fix something repeatedly | Missing config | Failing regression'
|
||||
ready-for-review: Code matches requirements + All validations pass + Follows standards + File List complete
|
||||
completion: 'All Tasks and Subtasks marked [x] and have tests→Validations and full regression passes (DON''T BE LAZY, EXECUTE ALL TESTS and CONFIRM)→Ensure File List is Complete→run the task execute-checklist for the checklist story-dod-checklist→set story status: ''Ready for Review''→HALT'
|
||||
- develop-story:
|
||||
- order-of-execution: Read (first or next) task→Implement Task and its subtasks→Write tests→Execute validations→Only if ALL pass, then update the task checkbox with [x]→Update story section File List to ensure it lists and new or modified or deleted source file→repeat order-of-execution until complete
|
||||
- story-file-updates-ONLY:
|
||||
- CRITICAL: ONLY UPDATE THE STORY FILE WITH UPDATES TO SECTIONS INDICATED BELOW. DO NOT MODIFY ANY OTHER SECTIONS.
|
||||
- CRITICAL: You are ONLY authorized to edit these specific sections of story files - Tasks / Subtasks Checkboxes, Dev Agent Record section and all its subsections, Agent Model Used, Debug Log References, Completion Notes List, File List, Change Log, Status
|
||||
- CRITICAL: DO NOT modify Status, Story, Acceptance Criteria, Dev Notes, Testing sections, or any other sections not listed above
|
||||
- blocking: 'HALT for: Unapproved deps needed, confirm with user | Ambiguous after story check | 3 failures attempting to implement or fix something repeatedly | Missing config | Failing regression'
|
||||
- ready-for-review: Code matches requirements + All validations pass + Follows standards + File List complete
|
||||
- completion: 'All Tasks and Subtasks marked [x] and have tests→Validations and full regression passes (DON''T BE LAZY, EXECUTE ALL TESTS and CONFIRM)→Ensure File List is Complete→run the task execute-checklist for the checklist story-dod-checklist→set story status: ''Ready for Review''→HALT'
|
||||
dependencies:
|
||||
tasks:
|
||||
- execute-checklist.md
|
||||
|
||||
@@ -85,9 +85,9 @@ Once planning is complete and documents are sharded, BMad follows a structured d
|
||||
graph TD
|
||||
A["Development Phase Start"] --> B["SM: Reviews Previous Story Dev/QA Notes"]
|
||||
B --> B2["SM: Drafts Next Story from Sharded Epic + Architecture"]
|
||||
B2 --> B3{"QA: Review Story Draft (Optional)"}
|
||||
B3 -->|Review Requested| B4["QA: Review Story Against Artifacts"]
|
||||
B3 -->|Skip Review| C{"User Approval"}
|
||||
B2 --> B3{"PO: Validate Story Draft (Optional)"}
|
||||
B3 -->|Validation Requested| B4["PO: Validate Story Against Artifacts"]
|
||||
B3 -->|Skip Validation| C{"User Approval"}
|
||||
B4 --> C
|
||||
C -->|Approved| D["Dev: Sequential Task Execution"]
|
||||
C -->|Needs Changes| B2
|
||||
4
package-lock.json
generated
4
package-lock.json
generated
@@ -1,12 +1,12 @@
|
||||
{
|
||||
"name": "bmad-method",
|
||||
"version": "4.33.1",
|
||||
"version": "4.35.3",
|
||||
"lockfileVersion": 3,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "bmad-method",
|
||||
"version": "4.33.1",
|
||||
"version": "4.35.3",
|
||||
"license": "MIT",
|
||||
"dependencies": {
|
||||
"@kayvan/markdown-tree-parser": "^1.5.0",
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "bmad-method",
|
||||
"version": "4.33.1",
|
||||
"version": "4.35.3",
|
||||
"description": "Breakthrough Method of Agile AI-driven Development",
|
||||
"main": "tools/cli.js",
|
||||
"bin": {
|
||||
|
||||
@@ -93,6 +93,7 @@ program
|
||||
const agents = await builder.resolver.listAgents();
|
||||
console.log('Available agents:');
|
||||
agents.forEach(agent => console.log(` - ${agent}`));
|
||||
process.exit(0);
|
||||
});
|
||||
|
||||
program
|
||||
@@ -103,6 +104,7 @@ program
|
||||
const expansions = await builder.listExpansionPacks();
|
||||
console.log('Available expansion packs:');
|
||||
expansions.forEach(expansion => console.log(` - ${expansion}`));
|
||||
process.exit(0);
|
||||
});
|
||||
|
||||
program
|
||||
|
||||
@@ -41,7 +41,7 @@ program
|
||||
.option('-f, --full', 'Install complete BMad Method')
|
||||
.option('-x, --expansion-only', 'Install only expansion packs (no bmad-core)')
|
||||
.option('-d, --directory <path>', 'Installation directory')
|
||||
.option('-i, --ide <ide...>', 'Configure for specific IDE(s) - can specify multiple (cursor, claude-code, windsurf, trae, roo, cline, gemini, github-copilot, other)')
|
||||
.option('-i, --ide <ide...>', 'Configure for specific IDE(s) - can specify multiple (cursor, claude-code, windsurf, trae, roo, kilo, cline, gemini, qwen-code, github-copilot, other)')
|
||||
.option('-e, --expansion-packs <packs...>', 'Install specific expansion packs (can specify multiple)')
|
||||
.action(async (options) => {
|
||||
try {
|
||||
@@ -311,8 +311,10 @@ async function promptInstallation() {
|
||||
{ name: 'Windsurf', value: 'windsurf' },
|
||||
{ name: 'Trae', value: 'trae' }, // { name: 'Trae', value: 'trae'}
|
||||
{ name: 'Roo Code', value: 'roo' },
|
||||
{ name: 'Kilo Code', value: 'kilo' },
|
||||
{ name: 'Cline', value: 'cline' },
|
||||
{ name: 'Gemini CLI', value: 'gemini' },
|
||||
{ name: 'Qwen Code', value: 'qwen-code' },
|
||||
{ name: 'Github Copilot', value: 'github-copilot' }
|
||||
]
|
||||
}
|
||||
|
||||
@@ -89,4 +89,25 @@ ide-configurations:
|
||||
# 3. The agent will adopt that persona for the conversation
|
||||
# 4. Requires VS Code 1.101+ with `chat.agent.enabled: true` in settings
|
||||
# 5. Agent files are stored in .github/chatmodes/
|
||||
# 6. Use `*help` to see available commands and agents
|
||||
# 6. Use `*help` to see available commands and agents
|
||||
kilo:
|
||||
name: Kilo Code
|
||||
format: custom-modes
|
||||
file: .kilocodemodes
|
||||
instructions: |
|
||||
# To use BMAD agents in Kilo Code:
|
||||
# 1. Open the mode selector in VSCode
|
||||
# 2. Select a bmad-{agent} mode (e.g. "bmad-dev")
|
||||
# 3. The AI adopts that agent's persona and capabilities
|
||||
|
||||
qwen-code:
|
||||
name: Qwen Code
|
||||
rule-dir: .qwen/bmad-method/
|
||||
format: single-file
|
||||
command-suffix: .md
|
||||
instructions: |
|
||||
# To use BMad agents with Qwen Code:
|
||||
# 1. The installer creates a .qwen/bmad-method/ directory in your project.
|
||||
# 2. It concatenates all agent files into a single QWEN.md file.
|
||||
# 3. Simply mention the agent in your prompt (e.g., "As *dev, ...").
|
||||
# 4. The Qwen Code CLI will automatically have the context for that agent.
|
||||
@@ -53,10 +53,14 @@ class IdeSetup extends BaseIdeSetup {
|
||||
return this.setupRoo(installDir, selectedAgent);
|
||||
case "cline":
|
||||
return this.setupCline(installDir, selectedAgent);
|
||||
case "kilo":
|
||||
return this.setupKilocode(installDir, selectedAgent);
|
||||
case "gemini":
|
||||
return this.setupGeminiCli(installDir, selectedAgent);
|
||||
case "github-copilot":
|
||||
return this.setupGitHubCopilot(installDir, selectedAgent, spinner, preConfiguredSettings);
|
||||
case "qwen-code":
|
||||
return this.setupQwenCode(installDir, selectedAgent);
|
||||
default:
|
||||
console.log(chalk.yellow(`\nIDE ${ide} not yet supported`));
|
||||
return false;
|
||||
@@ -675,11 +679,17 @@ class IdeSetup extends BaseIdeSetup {
|
||||
? roleDefinitionMatch[1].trim()
|
||||
: `You are a ${title} specializing in ${title.toLowerCase()} tasks and responsibilities.`;
|
||||
|
||||
|
||||
// Add permissions based on agent type
|
||||
const permissions = agentPermissions[agentId];
|
||||
// Build mode entry with proper formatting (matching exact indentation)
|
||||
// Avoid double "bmad-" prefix for agents that already have it
|
||||
const slug = agentId.startsWith('bmad-') ? agentId : `bmad-${agentId}`;
|
||||
newModesContent += ` - slug: ${slug}\n`;
|
||||
newModesContent += ` name: '${icon} ${title}'\n`;
|
||||
if (permissions) {
|
||||
newModesContent += ` description: '${permissions.description}'\n`;
|
||||
}
|
||||
newModesContent += ` roleDefinition: ${roleDefinition}\n`;
|
||||
newModesContent += ` whenToUse: ${whenToUse}\n`;
|
||||
// Get relative path from installDir to agent file
|
||||
@@ -688,8 +698,6 @@ class IdeSetup extends BaseIdeSetup {
|
||||
newModesContent += ` groups:\n`;
|
||||
newModesContent += ` - read\n`;
|
||||
|
||||
// Add permissions based on agent type
|
||||
const permissions = agentPermissions[agentId];
|
||||
if (permissions) {
|
||||
newModesContent += ` - - edit\n`;
|
||||
newModesContent += ` - fileRegex: ${permissions.fileRegex}\n`;
|
||||
@@ -722,7 +730,98 @@ class IdeSetup extends BaseIdeSetup {
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
async setupKilocode(installDir, selectedAgent) {
|
||||
const filePath = path.join(installDir, ".kilocodemodes");
|
||||
const agents = selectedAgent ? [selectedAgent] : await this.getAllAgentIds(installDir);
|
||||
|
||||
let existingModes = [], existingContent = "";
|
||||
if (await fileManager.pathExists(filePath)) {
|
||||
existingContent = await fileManager.readFile(filePath);
|
||||
for (const match of existingContent.matchAll(/- slug: ([\w-]+)/g)) {
|
||||
existingModes.push(match[1]);
|
||||
}
|
||||
console.log(chalk.yellow(`Found existing .kilocodemodes file with ${existingModes.length} modes`));
|
||||
}
|
||||
|
||||
const config = await this.loadIdeAgentConfig();
|
||||
const permissions = config['roo-permissions'] || {}; // reuse same roo permissions block (Kilo Code understands same mode schema)
|
||||
|
||||
let newContent = "";
|
||||
|
||||
for (const agentId of agents) {
|
||||
const slug = agentId.startsWith('bmad-') ? agentId : `bmad-${agentId}`;
|
||||
if (existingModes.includes(slug)) {
|
||||
console.log(chalk.dim(`Skipping ${agentId} - already exists in .kilocodemodes`));
|
||||
continue;
|
||||
}
|
||||
|
||||
const agentPath = await this.findAgentPath(agentId, installDir);
|
||||
if (!agentPath) {
|
||||
console.log(chalk.red(`✗ Could not find agent file for ${agentId}`));
|
||||
continue;
|
||||
}
|
||||
|
||||
const agentContent = await fileManager.readFile(agentPath);
|
||||
const yamlMatch = agentContent.match(/```ya?ml\r?\n([\s\S]*?)```/);
|
||||
if (!yamlMatch) {
|
||||
console.log(chalk.red(`✗ Could not extract YAML block for ${agentId}`));
|
||||
continue;
|
||||
}
|
||||
|
||||
const yaml = yamlMatch[1];
|
||||
|
||||
// Robust fallback for title and icon
|
||||
const title = (yaml.match(/title:\s*(.+)/)?.[1]?.trim()) || await this.getAgentTitle(agentId, installDir);
|
||||
const icon = (yaml.match(/icon:\s*(.+)/)?.[1]?.trim()) || '🤖';
|
||||
const whenToUse = (yaml.match(/whenToUse:\s*"(.+)"/)?.[1]?.trim()) || `Use for ${title} tasks`;
|
||||
const roleDefinition = (yaml.match(/roleDefinition:\s*"(.+)"/)?.[1]?.trim()) ||
|
||||
`You are a ${title} specializing in ${title.toLowerCase()} tasks and responsibilities.`;
|
||||
|
||||
const relativePath = path.relative(installDir, agentPath).replace(/\\/g, '/');
|
||||
const customInstructions = `CRITICAL Read the full YAML from ${relativePath} start activation to alter your state of being follow startup section instructions stay in this being until told to exit this mode`;
|
||||
|
||||
// Add permissions from config if they exist
|
||||
const agentPermission = permissions[agentId];
|
||||
|
||||
// Begin .kilocodemodes block
|
||||
newContent += ` - slug: ${slug}\n`;
|
||||
newContent += ` name: '${icon} ${title}'\n`;
|
||||
if (agentPermission) {
|
||||
newContent += ` description: '${agentPermission.description}'\n`;
|
||||
}
|
||||
|
||||
newContent += ` roleDefinition: ${roleDefinition}\n`;
|
||||
newContent += ` whenToUse: ${whenToUse}\n`;
|
||||
newContent += ` customInstructions: ${customInstructions}\n`;
|
||||
newContent += ` groups:\n`;
|
||||
newContent += ` - read\n`;
|
||||
|
||||
|
||||
if (agentPermission) {
|
||||
newContent += ` - - edit\n`;
|
||||
newContent += ` - fileRegex: ${agentPermission.fileRegex}\n`;
|
||||
newContent += ` description: ${agentPermission.description}\n`;
|
||||
} else {
|
||||
// Fallback to generic edit
|
||||
newContent += ` - edit\n`;
|
||||
}
|
||||
|
||||
console.log(chalk.green(`✓ Added Kilo mode: ${slug} (${icon} ${title})`));
|
||||
}
|
||||
|
||||
const finalContent = existingContent
|
||||
? existingContent.trim() + "\n" + newContent
|
||||
: "customModes:\n" + newContent;
|
||||
|
||||
await fileManager.writeFile(filePath, finalContent);
|
||||
console.log(chalk.green("✓ Created .kilocodemodes file in project root"));
|
||||
console.log(chalk.green(`✓ KiloCode setup complete!`));
|
||||
console.log(chalk.dim("Custom modes will be available when you open this project in KiloCode"));
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
async setupCline(installDir, selectedAgent) {
|
||||
const clineRulesDir = path.join(installDir, ".clinerules");
|
||||
const agents = selectedAgent ? [selectedAgent] : await this.getAllAgentIds(installDir);
|
||||
@@ -880,6 +979,106 @@ class IdeSetup extends BaseIdeSetup {
|
||||
return true;
|
||||
}
|
||||
|
||||
async setupQwenCode(installDir, selectedAgent) {
|
||||
const qwenDir = path.join(installDir, ".qwen");
|
||||
const bmadMethodDir = path.join(qwenDir, "bmad-method");
|
||||
await fileManager.ensureDirectory(bmadMethodDir);
|
||||
|
||||
// Update logic for existing settings.json
|
||||
const settingsPath = path.join(qwenDir, "settings.json");
|
||||
if (await fileManager.pathExists(settingsPath)) {
|
||||
try {
|
||||
const settingsContent = await fileManager.readFile(settingsPath);
|
||||
const settings = JSON.parse(settingsContent);
|
||||
let updated = false;
|
||||
|
||||
// Handle contextFileName property
|
||||
if (settings.contextFileName && Array.isArray(settings.contextFileName)) {
|
||||
const originalLength = settings.contextFileName.length;
|
||||
settings.contextFileName = settings.contextFileName.filter(
|
||||
(fileName) => !fileName.startsWith("agents/")
|
||||
);
|
||||
if (settings.contextFileName.length !== originalLength) {
|
||||
updated = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (updated) {
|
||||
await fileManager.writeFile(
|
||||
settingsPath,
|
||||
JSON.stringify(settings, null, 2)
|
||||
);
|
||||
console.log(chalk.green("✓ Updated .qwen/settings.json - removed agent file references"));
|
||||
}
|
||||
} catch (error) {
|
||||
console.warn(
|
||||
chalk.yellow("Could not update .qwen/settings.json"),
|
||||
error
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
// Remove old agents directory
|
||||
const agentsDir = path.join(qwenDir, "agents");
|
||||
if (await fileManager.pathExists(agentsDir)) {
|
||||
await fileManager.removeDirectory(agentsDir);
|
||||
console.log(chalk.green("✓ Removed old .qwen/agents directory"));
|
||||
}
|
||||
|
||||
// Get all available agents
|
||||
const agents = selectedAgent ? [selectedAgent] : await this.getAllAgentIds(installDir);
|
||||
let concatenatedContent = "";
|
||||
|
||||
for (const agentId of agents) {
|
||||
// Find the source agent file
|
||||
const agentPath = await this.findAgentPath(agentId, installDir);
|
||||
|
||||
if (agentPath) {
|
||||
const agentContent = await fileManager.readFile(agentPath);
|
||||
|
||||
// Create properly formatted agent rule content (similar to gemini)
|
||||
let agentRuleContent = `# ${agentId.toUpperCase()} Agent Rule\n\n`;
|
||||
agentRuleContent += `This rule is triggered when the user types \`*${agentId}\` and activates the ${await this.getAgentTitle(
|
||||
agentId,
|
||||
installDir
|
||||
)} agent persona.\n\n`;
|
||||
agentRuleContent += "## Agent Activation\n\n";
|
||||
agentRuleContent +=
|
||||
"CRITICAL: Read the full YAML, start activation to alter your state of being, follow startup section instructions, stay in this being until told to exit this mode:\n\n";
|
||||
agentRuleContent += "```yaml\n";
|
||||
// Extract just the YAML content from the agent file
|
||||
const yamlContent = extractYamlFromAgent(agentContent);
|
||||
if (yamlContent) {
|
||||
agentRuleContent += yamlContent;
|
||||
}
|
||||
else {
|
||||
// If no YAML found, include the whole content minus the header
|
||||
agentRuleContent += agentContent.replace(/^#.*$/m, "").trim();
|
||||
}
|
||||
agentRuleContent += "\n```\n\n";
|
||||
agentRuleContent += "## File Reference\n\n";
|
||||
const relativePath = path.relative(installDir, agentPath).replace(/\\/g, '/');
|
||||
agentRuleContent += `The complete agent definition is available in [${relativePath}](${relativePath}).\n\n`;
|
||||
agentRuleContent += "## Usage\n\n";
|
||||
agentRuleContent += `When the user types \`*${agentId}\`, activate this ${await this.getAgentTitle(
|
||||
agentId,
|
||||
installDir
|
||||
)} persona and follow all instructions defined in the YAML configuration above.\n`;
|
||||
|
||||
// Add to concatenated content with separator
|
||||
concatenatedContent += agentRuleContent + "\n\n---\n\n";
|
||||
console.log(chalk.green(`✓ Added context for *${agentId}`));
|
||||
}
|
||||
}
|
||||
|
||||
// Write the concatenated content to QWEN.md
|
||||
const qwenMdPath = path.join(bmadMethodDir, "QWEN.md");
|
||||
await fileManager.writeFile(qwenMdPath, concatenatedContent);
|
||||
console.log(chalk.green(`\n✓ Created QWEN.md in ${bmadMethodDir}`));
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
async setupGitHubCopilot(installDir, selectedAgent, spinner = null, preConfiguredSettings = null) {
|
||||
// Configure VS Code workspace settings first to avoid UI conflicts with loading spinners
|
||||
await this.configureVsCodeSettings(installDir, spinner, preConfiguredSettings);
|
||||
|
||||
@@ -237,6 +237,10 @@ class Installer {
|
||||
// Copy common/ items to .bmad-core
|
||||
spinner.text = "Copying common utilities...";
|
||||
await this.copyCommonItems(installDir, ".bmad-core", spinner);
|
||||
|
||||
// Copy documentation files from docs/ to .bmad-core
|
||||
spinner.text = "Copying documentation files...";
|
||||
await this.copyDocsItems(installDir, ".bmad-core", spinner);
|
||||
|
||||
// Get list of all files for manifest
|
||||
const foundFiles = await resourceLocator.findFiles("**/*", {
|
||||
@@ -308,6 +312,11 @@ class Installer {
|
||||
spinner.text = "Copying common utilities...";
|
||||
const commonFiles = await this.copyCommonItems(installDir, ".bmad-core", spinner);
|
||||
files.push(...commonFiles);
|
||||
|
||||
// Copy documentation files from docs/ to .bmad-core
|
||||
spinner.text = "Copying documentation files...";
|
||||
const docFiles = await this.copyDocsItems(installDir, ".bmad-core", spinner);
|
||||
files.push(...docFiles);
|
||||
} else if (config.installType === "team") {
|
||||
// Team installation
|
||||
spinner.text = `Installing ${config.team} team...`;
|
||||
@@ -353,6 +362,11 @@ class Installer {
|
||||
spinner.text = "Copying common utilities...";
|
||||
const commonFiles = await this.copyCommonItems(installDir, ".bmad-core", spinner);
|
||||
files.push(...commonFiles);
|
||||
|
||||
// Copy documentation files from docs/ to .bmad-core
|
||||
spinner.text = "Copying documentation files...";
|
||||
const docFiles = await this.copyDocsItems(installDir, ".bmad-core", spinner);
|
||||
files.push(...docFiles);
|
||||
} else if (config.installType === "expansion-only") {
|
||||
// Expansion-only installation - DO NOT create .bmad-core
|
||||
// Only install expansion packs
|
||||
@@ -896,7 +910,7 @@ class Installer {
|
||||
}
|
||||
|
||||
// Important notice to read the user guide
|
||||
console.log(chalk.red.bold("\n📖 IMPORTANT: Please read the user guide installed at .bmad-core/user-guide.md"));
|
||||
console.log(chalk.red.bold("\n📖 IMPORTANT: Please read the user guide at docs/user-guide.md (also installed at .bmad-core/user-guide.md)"));
|
||||
console.log(chalk.red("This guide contains essential information about the BMad workflow and how to use the agents effectively."));
|
||||
}
|
||||
|
||||
@@ -1557,6 +1571,54 @@ class Installer {
|
||||
return copiedFiles;
|
||||
}
|
||||
|
||||
async copyDocsItems(installDir, targetSubdir, spinner) {
|
||||
const fs = require('fs').promises;
|
||||
const sourceBase = path.dirname(path.dirname(path.dirname(path.dirname(__filename)))); // Go up to project root
|
||||
const docsPath = path.join(sourceBase, 'docs');
|
||||
const targetPath = path.join(installDir, targetSubdir);
|
||||
const copiedFiles = [];
|
||||
|
||||
// Specific documentation files to copy
|
||||
const docFiles = [
|
||||
'enhanced-ide-development-workflow.md',
|
||||
'user-guide.md',
|
||||
'working-in-the-brownfield.md'
|
||||
];
|
||||
|
||||
// Check if docs/ exists
|
||||
if (!(await fileManager.pathExists(docsPath))) {
|
||||
console.warn('Warning: docs/ folder not found');
|
||||
return copiedFiles;
|
||||
}
|
||||
|
||||
// Copy specific documentation files from docs/ to target
|
||||
for (const docFile of docFiles) {
|
||||
const sourcePath = path.join(docsPath, docFile);
|
||||
const destPath = path.join(targetPath, docFile);
|
||||
|
||||
// Check if the source file exists
|
||||
if (await fileManager.pathExists(sourcePath)) {
|
||||
// Read the file content
|
||||
const content = await fs.readFile(sourcePath, 'utf8');
|
||||
|
||||
// Replace {root} with the target subdirectory
|
||||
const updatedContent = content.replace(/\{root\}/g, targetSubdir);
|
||||
|
||||
// Ensure directory exists
|
||||
await fileManager.ensureDirectory(path.dirname(destPath));
|
||||
|
||||
// Write the updated content
|
||||
await fs.writeFile(destPath, updatedContent, 'utf8');
|
||||
copiedFiles.push(path.join(targetSubdir, docFile));
|
||||
}
|
||||
}
|
||||
|
||||
if (copiedFiles.length > 0) {
|
||||
console.log(chalk.dim(` Added ${copiedFiles.length} documentation files`));
|
||||
}
|
||||
return copiedFiles;
|
||||
}
|
||||
|
||||
async detectExpansionPacks(installDir) {
|
||||
const expansionPacks = {};
|
||||
const glob = require("glob");
|
||||
@@ -1729,7 +1791,7 @@ class Installer {
|
||||
const manifestPath = path.join(bmadDir, "install-manifest.yaml");
|
||||
|
||||
if (await fileManager.pathExists(manifestPath)) {
|
||||
return bmadDir;
|
||||
return currentDir; // Return parent directory, not .bmad-core itself
|
||||
}
|
||||
|
||||
currentDir = path.dirname(currentDir);
|
||||
@@ -1739,7 +1801,7 @@ class Installer {
|
||||
if (path.basename(process.cwd()) === ".bmad-core") {
|
||||
const manifestPath = path.join(process.cwd(), "install-manifest.yaml");
|
||||
if (await fileManager.pathExists(manifestPath)) {
|
||||
return process.cwd();
|
||||
return path.dirname(process.cwd()); // Return parent directory
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "bmad-method",
|
||||
"version": "4.33.1",
|
||||
"version": "4.35.3",
|
||||
"description": "BMad Method installer - AI-powered Agile development framework",
|
||||
"main": "lib/installer.js",
|
||||
"bin": {
|
||||
|
||||
Reference in New Issue
Block a user