bmad-method 4.22.1 → 4.24.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 (42) hide show
  1. package/CHANGELOG.md +19 -0
  2. package/README.md +3 -2
  3. package/bmad-core/agents/bmad-master.md +14 -1
  4. package/bmad-core/agents/bmad-orchestrator.md +14 -0
  5. package/bmad-core/core-config.yml +5 -0
  6. package/bmad-core/data/bmad-kb.md +3 -1
  7. package/bmad-core/tasks/create-brownfield-story.md +355 -0
  8. package/bmad-core/tasks/create-next-story.md +25 -0
  9. package/bmad-core/tasks/create-workflow-plan.md +289 -0
  10. package/bmad-core/tasks/update-workflow-plan.md +248 -0
  11. package/bmad-core/templates/brownfield-prd-tmpl.md +52 -28
  12. package/bmad-core/utils/plan-management.md +223 -0
  13. package/bmad-core/workflows/brownfield-fullstack.yml +240 -55
  14. package/bmad-core/workflows/brownfield-service.yml +110 -36
  15. package/bmad-core/workflows/brownfield-ui.yml +110 -36
  16. package/bmad-core/workflows/greenfield-fullstack.yml +110 -36
  17. package/bmad-core/workflows/greenfield-service.yml +110 -36
  18. package/bmad-core/workflows/greenfield-ui.yml +110 -36
  19. package/common/tasks/create-doc.md +21 -1
  20. package/dist/agents/analyst.txt +24 -2
  21. package/dist/agents/architect.txt +21 -1
  22. package/dist/agents/bmad-master.txt +884 -31
  23. package/dist/agents/bmad-orchestrator.txt +807 -2
  24. package/dist/agents/pm.txt +73 -29
  25. package/dist/agents/sm.txt +25 -0
  26. package/dist/agents/ux-expert.txt +21 -1
  27. package/dist/expansion-packs/bmad-2d-phaser-game-dev/agents/game-designer.txt +21 -1
  28. package/dist/expansion-packs/bmad-2d-phaser-game-dev/teams/phaser-2d-nodejs-game-team.txt +804 -1
  29. package/dist/expansion-packs/bmad-infrastructure-devops/agents/infra-devops-platform.txt +21 -1
  30. package/dist/teams/team-all.txt +1676 -267
  31. package/dist/teams/team-fullstack.txt +1651 -267
  32. package/dist/teams/team-ide-minimal.txt +832 -2
  33. package/dist/teams/team-no-ui.txt +1080 -103
  34. package/docs/bmad-workflow-guide.md +2 -1
  35. package/docs/core-architecture.md +2 -1
  36. package/package.json +1 -1
  37. package/tools/installer/bin/bmad.js +3 -2
  38. package/tools/installer/config/install.config.yml +13 -0
  39. package/tools/installer/lib/ide-setup.js +214 -1
  40. package/tools/installer/lib/installer.js +3 -13
  41. package/tools/installer/package.json +1 -1
  42. package/tools/lib/dependency-resolver.js +2 -2
@@ -22,7 +22,7 @@ The BMAD Method follows a structured approach to AI-assisted software developmen
22
22
  ```
23
23
 
24
24
  - Choose "Complete installation"
25
- - Select your IDE (Cursor, Claude Code, Windsurf, or Roo Code)
25
+ - Select your IDE (Cursor, Claude Code, Windsurf, Roo Code, or VS Code Copilot)
26
26
 
27
27
  2. **Verify installation**:
28
28
  - `.bmad-core/` folder created with all agents
@@ -113,6 +113,7 @@ Follow the SM → Dev cycle for systematic story development:
113
113
  - **Cursor**: `@agent-name` (e.g., `@bmad-master`)
114
114
  - **Windsurf**: `@agent-name` (e.g., `@bmad-master`)
115
115
  - **Roo Code**: Select mode from mode selector (e.g., `bmad-bmad-master`)
116
+ - **VS Code Copilot**: Open the Chat view (`⌃⌘I` on Mac, `Ctrl+Alt+I` on Windows/Linux) and select **Agent** from the chat mode selector.
116
117
 
117
118
  ### Chat Management:
118
119
 
@@ -292,7 +292,8 @@ bmad-method/
292
292
  │ │ ├── cline-guide.md
293
293
  │ │ ├── gemini-cli-guide.md
294
294
  │ │ ├── roo-code-guide.md
295
- │ │ └── windsurf-guide.md
295
+ │ │ ├── windsurf-guide.md
296
+ │ │ └── vs-code-copilot-guide.md
296
297
  │ ├── bmad-workflow-guide.md # Universal workflow guide
297
298
  │ ├── core-architecture.md # This document
298
299
  │ ├── expansion-packs.md # Expansion pack guide
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "bmad-method",
3
- "version": "4.22.1",
3
+ "version": "4.24.0",
4
4
  "description": "Breakthrough Method of Agile AI-driven Development",
5
5
  "main": "tools/cli.js",
6
6
  "bin": {
@@ -50,7 +50,7 @@ program
50
50
  .option('-f, --full', 'Install complete BMAD Method')
51
51
  .option('-x, --expansion-only', 'Install only expansion packs (no bmad-core)')
52
52
  .option('-d, --directory <path>', 'Installation directory')
53
- .option('-i, --ide <ide...>', 'Configure for specific IDE(s) - can specify multiple (cursor, claude-code, windsurf, roo, cline, gemini, other)')
53
+ .option('-i, --ide <ide...>', 'Configure for specific IDE(s) - can specify multiple (cursor, claude-code, windsurf, roo, cline, gemini, vs-code-copilot, other)')
54
54
  .option('-e, --expansion-packs <packs...>', 'Install specific expansion packs (can specify multiple)')
55
55
  .action(async (options) => {
56
56
  try {
@@ -236,7 +236,8 @@ async function promptInstallation() {
236
236
  { name: 'Windsurf', value: 'windsurf' },
237
237
  { name: 'Roo Code', value: 'roo' },
238
238
  { name: 'Cline', value: 'cline' },
239
- { name: 'Gemini CLI', value: 'gemini' }
239
+ { name: 'Gemini CLI', value: 'gemini' },
240
+ { name: 'VS Code Copilot', value: 'vs-code-copilot' }
240
241
  ]
241
242
  }
242
243
  ]);
@@ -67,3 +67,16 @@ ide-configurations:
67
67
  # 2. It also configures .gemini/settings.json to load all agent files.
68
68
  # 3. Simply mention the agent in your prompt (e.g., "As @dev, ...").
69
69
  # 4. The Gemini CLI will automatically have the context for that agent.
70
+ vs-code-copilot:
71
+ name: VS Code Copilot
72
+ rule-dir: .github/chatmodes/
73
+ format: multi-file
74
+ command-suffix: .md
75
+ instructions: |
76
+ # To use BMAD agents with VS Code Copilot:
77
+ # 1. The installer creates a .github/chatmodes/ directory in your project
78
+ # 2. Open the Chat view (`⌃⌘I` on Mac, `Ctrl+Alt+I` on Windows/Linux) and select **Agent** from the chat mode selector.
79
+ # 3. The agent will adopt that persona for the conversation
80
+ # 4. Requires VS Code 1.99+ with `chat.agent.enabled: true` in settings
81
+ # 5. Agent files are stored in .github/chatmodes/
82
+ # 6. Use `/help` to see available commands and agents
@@ -6,12 +6,16 @@ const configLoader = require("./config-loader");
6
6
 
7
7
  // Dynamic import for ES module
8
8
  let chalk;
9
+ let inquirer;
9
10
 
10
11
  // Initialize ES modules
11
12
  async function initializeModules() {
12
13
  if (!chalk) {
13
14
  chalk = (await import("chalk")).default;
14
15
  }
16
+ if (!inquirer) {
17
+ inquirer = (await import("inquirer")).default;
18
+ }
15
19
  }
16
20
 
17
21
  class IdeSetup {
@@ -36,7 +40,7 @@ class IdeSetup {
36
40
  }
37
41
  }
38
42
 
39
- async setup(ide, installDir, selectedAgent = null) {
43
+ async setup(ide, installDir, selectedAgent = null, spinner = null) {
40
44
  await initializeModules();
41
45
  const ideConfig = await configLoader.getIdeConfiguration(ide);
42
46
 
@@ -58,6 +62,8 @@ class IdeSetup {
58
62
  return this.setupCline(installDir, selectedAgent);
59
63
  case "gemini":
60
64
  return this.setupGeminiCli(installDir, selectedAgent);
65
+ case "vs-code-copilot":
66
+ return this.setupVsCodeCopilot(installDir, selectedAgent, spinner);
61
67
  default:
62
68
  console.log(chalk.yellow(`\nIDE ${ide} not yet supported`));
63
69
  return false;
@@ -507,6 +513,213 @@ class IdeSetup {
507
513
 
508
514
  return true;
509
515
  }
516
+
517
+ async setupVsCodeCopilot(installDir, selectedAgent, spinner = null) {
518
+ await initializeModules();
519
+
520
+ // Configure VS Code workspace settings first to avoid UI conflicts with loading spinners
521
+ await this.configureVsCodeSettings(installDir, spinner);
522
+
523
+ const chatmodesDir = path.join(installDir, ".github", "chatmodes");
524
+ const agents = selectedAgent ? [selectedAgent] : await this.getAllAgentIds(installDir);
525
+
526
+ await fileManager.ensureDirectory(chatmodesDir);
527
+
528
+ for (const agentId of agents) {
529
+ // Find the agent file
530
+ const agentPath = await this.findAgentPath(agentId, installDir);
531
+ const chatmodePath = path.join(chatmodesDir, `${agentId}.chatmode.md`);
532
+
533
+ if (agentPath) {
534
+ // Create chat mode file with agent content
535
+ const agentContent = await fileManager.readFile(agentPath);
536
+ const agentTitle = await this.getAgentTitle(agentId, installDir);
537
+
538
+ // Extract whenToUse for the description
539
+ const yamlMatch = agentContent.match(/```ya?ml\n([\s\S]*?)```/);
540
+ let description = `Activates the ${agentTitle} agent persona.`;
541
+ if (yamlMatch) {
542
+ const whenToUseMatch = yamlMatch[1].match(/whenToUse:\s*"(.*?)"/);
543
+ if (whenToUseMatch && whenToUseMatch[1]) {
544
+ description = whenToUseMatch[1];
545
+ }
546
+ }
547
+
548
+ let chatmodeContent = `---
549
+ description: "${description.replace(/"/g, '\\"')}"
550
+ tools: ['changes', 'codebase', 'fetch', 'findTestFiles', 'githubRepo', 'problems', 'usages']
551
+ ---
552
+
553
+ `;
554
+ chatmodeContent += agentContent;
555
+
556
+ await fileManager.writeFile(chatmodePath, chatmodeContent);
557
+ console.log(chalk.green(`✓ Created chat mode: ${agentId}.chatmode.md`));
558
+ }
559
+ }
560
+
561
+ console.log(chalk.green(`\n✓ VS Code Copilot setup complete!`));
562
+ console.log(chalk.dim(`You can now find the BMAD agents in the Chat view's mode selector.`));
563
+
564
+ return true;
565
+ }
566
+
567
+ async configureVsCodeSettings(installDir, spinner) {
568
+ await initializeModules(); // Ensure inquirer is loaded
569
+ const vscodeDir = path.join(installDir, ".vscode");
570
+ const settingsPath = path.join(vscodeDir, "settings.json");
571
+
572
+ await fileManager.ensureDirectory(vscodeDir);
573
+
574
+ // Read existing settings if they exist
575
+ let existingSettings = {};
576
+ if (await fileManager.pathExists(settingsPath)) {
577
+ try {
578
+ const existingContent = await fileManager.readFile(settingsPath);
579
+ existingSettings = JSON.parse(existingContent);
580
+ console.log(chalk.yellow("Found existing .vscode/settings.json. Merging BMAD settings..."));
581
+ } catch (error) {
582
+ console.warn(chalk.yellow("Could not parse existing settings.json. Creating new one."));
583
+ existingSettings = {};
584
+ }
585
+ }
586
+
587
+ // Clear any previous output and add spacing to avoid conflicts with loaders
588
+ console.log('\n'.repeat(2));
589
+ console.log(chalk.blue("🔧 VS Code Copilot Agent Settings Configuration"));
590
+ console.log(chalk.dim("BMAD works best with specific VS Code settings for optimal agent experience."));
591
+ console.log(''); // Add extra spacing
592
+
593
+ const { configChoice } = await inquirer.prompt([
594
+ {
595
+ type: 'list',
596
+ name: 'configChoice',
597
+ message: 'How would you like to configure VS Code Copilot settings?',
598
+ choices: [
599
+ {
600
+ name: 'Use recommended defaults (fastest setup)',
601
+ value: 'defaults'
602
+ },
603
+ {
604
+ name: 'Configure each setting manually (customize to your preferences)',
605
+ value: 'manual'
606
+ },
607
+ {
608
+ name: 'Skip settings configuration (I\'ll configure manually later)\n',
609
+ value: 'skip'
610
+ }
611
+ ],
612
+ default: 'defaults'
613
+ }
614
+ ]);
615
+
616
+ let bmadSettings = {};
617
+
618
+ if (configChoice === 'skip') {
619
+ console.log(chalk.yellow("⚠️ Skipping VS Code settings configuration."));
620
+ console.log(chalk.dim("You can manually configure these settings in .vscode/settings.json:"));
621
+ console.log(chalk.dim(" • chat.agent.enabled: true"));
622
+ console.log(chalk.dim(" • chat.agent.maxRequests: 15"));
623
+ console.log(chalk.dim(" • github.copilot.chat.agent.runTasks: true"));
624
+ console.log(chalk.dim(" • chat.mcp.discovery.enabled: true"));
625
+ console.log(chalk.dim(" • github.copilot.chat.agent.autoFix: true"));
626
+ console.log(chalk.dim(" • chat.tools.autoApprove: false"));
627
+ return true;
628
+ }
629
+
630
+ if (configChoice === 'defaults') {
631
+ // Use recommended defaults
632
+ bmadSettings = {
633
+ "chat.agent.enabled": true,
634
+ "chat.agent.maxRequests": 15,
635
+ "github.copilot.chat.agent.runTasks": true,
636
+ "chat.mcp.discovery.enabled": true,
637
+ "github.copilot.chat.agent.autoFix": true,
638
+ "chat.tools.autoApprove": false
639
+ };
640
+ console.log(chalk.green("✓ Using recommended BMAD defaults for VS Code Copilot settings"));
641
+ } else {
642
+ // Manual configuration
643
+ console.log(chalk.blue("\n📋 Let's configure each setting for your preferences:"));
644
+
645
+ // Pause spinner during manual configuration prompts
646
+ let spinnerWasActive = false;
647
+ if (spinner && spinner.isSpinning) {
648
+ spinner.stop();
649
+ spinnerWasActive = true;
650
+ }
651
+
652
+ const manualSettings = await inquirer.prompt([
653
+ {
654
+ type: 'input',
655
+ name: 'maxRequests',
656
+ message: 'Maximum requests per agent session (recommended: 15)?',
657
+ default: '15',
658
+ validate: (input) => {
659
+ const num = parseInt(input);
660
+ if (isNaN(num) || num < 1 || num > 50) {
661
+ return 'Please enter a number between 1 and 50';
662
+ }
663
+ return true;
664
+ }
665
+ },
666
+ {
667
+ type: 'confirm',
668
+ name: 'runTasks',
669
+ message: 'Allow agents to run workspace tasks (package.json scripts, etc.)?',
670
+ default: true
671
+ },
672
+ {
673
+ type: 'confirm',
674
+ name: 'mcpDiscovery',
675
+ message: 'Enable MCP (Model Context Protocol) server discovery?',
676
+ default: true
677
+ },
678
+ {
679
+ type: 'confirm',
680
+ name: 'autoFix',
681
+ message: 'Enable automatic error detection and fixing in generated code?',
682
+ default: true
683
+ },
684
+ {
685
+ type: 'confirm',
686
+ name: 'autoApprove',
687
+ message: 'Auto-approve ALL tools without confirmation? (⚠️ EXPERIMENTAL - less secure)',
688
+ default: false
689
+ }
690
+ ]);
691
+
692
+ // Restart spinner if it was active before prompts
693
+ if (spinner && spinnerWasActive) {
694
+ spinner.start();
695
+ }
696
+
697
+ bmadSettings = {
698
+ "chat.agent.enabled": true, // Always enabled - required for BMAD agents
699
+ "chat.agent.maxRequests": parseInt(manualSettings.maxRequests),
700
+ "github.copilot.chat.agent.runTasks": manualSettings.runTasks,
701
+ "chat.mcp.discovery.enabled": manualSettings.mcpDiscovery,
702
+ "github.copilot.chat.agent.autoFix": manualSettings.autoFix,
703
+ "chat.tools.autoApprove": manualSettings.autoApprove
704
+ };
705
+
706
+ console.log(chalk.green("✓ Custom settings configured"));
707
+ }
708
+
709
+ // Merge settings (existing settings take precedence to avoid overriding user preferences)
710
+ const mergedSettings = { ...bmadSettings, ...existingSettings };
711
+
712
+ // Write the updated settings
713
+ await fileManager.writeFile(settingsPath, JSON.stringify(mergedSettings, null, 2));
714
+
715
+ console.log(chalk.green("✓ VS Code workspace settings configured successfully"));
716
+ console.log(chalk.dim(" Settings written to .vscode/settings.json:"));
717
+ Object.entries(bmadSettings).forEach(([key, value]) => {
718
+ console.log(chalk.dim(` • ${key}: ${value}`));
719
+ });
720
+ console.log(chalk.dim(""));
721
+ console.log(chalk.dim("You can modify these settings anytime in .vscode/settings.json"));
722
+ }
510
723
  }
511
724
 
512
725
  module.exports = new IdeSetup();
@@ -372,7 +372,7 @@ class Installer {
372
372
  if (ides.length > 0) {
373
373
  for (const ide of ides) {
374
374
  spinner.text = `Setting up ${ide} integration...`;
375
- await ideSetup.setup(ide, installDir, config.agent);
375
+ await ideSetup.setup(ide, installDir, config.agent, spinner);
376
376
  }
377
377
  }
378
378
 
@@ -757,12 +757,7 @@ class Installer {
757
757
  const ides = manifest.ides_setup || [];
758
758
  if (ides.includes('cursor')) {
759
759
  console.log(chalk.yellow.bold("\n⚠️ IMPORTANT: Cursor Custom Modes Update Required"));
760
- console.log(chalk.yellow("Since agent files have been repaired, you need to manually update your Cursor custom modes:"));
761
- console.log(chalk.yellow("1. Open Cursor Settings (Cmd/Ctrl + ,)"));
762
- console.log(chalk.yellow("2. Go to: Features > Cursor Tab > Custom Modes"));
763
- console.log(chalk.yellow("3. Update each custom mode with the latest agent templates from:"));
764
- console.log(chalk.yellow(` ${path.join(installDir, '.bmad-core', 'agents')}`));
765
- console.log(chalk.yellow("4. Copy the full content of each agent file into the corresponding custom mode"));
760
+ console.log(chalk.yellow("Since agent files have been repaired, you need to update any custom agent modes configured in the Cursor custom agent GUI per the Cursor docs."));
766
761
  }
767
762
 
768
763
  } catch (error) {
@@ -861,12 +856,7 @@ class Installer {
861
856
  // Warning for Cursor custom modes if agents were updated
862
857
  if (options.isUpdate && ides.includes('cursor')) {
863
858
  console.log(chalk.yellow.bold("\n⚠️ IMPORTANT: Cursor Custom Modes Update Required"));
864
- console.log(chalk.yellow("Since agents have been updated, you need to manually update your Cursor custom modes:"));
865
- console.log(chalk.yellow("1. Open Cursor Settings (Cmd/Ctrl + ,)"));
866
- console.log(chalk.yellow("2. Go to: Features > Cursor Tab > Custom Modes"));
867
- console.log(chalk.yellow("3. Update each custom mode with the latest agent templates from:"));
868
- console.log(chalk.yellow(` ${path.join(installDir, '.bmad-core', 'agents')}`));
869
- console.log(chalk.yellow("4. Copy the full content of each agent file into the corresponding custom mode"));
859
+ console.log(chalk.yellow("Since agents have been updated, you need to update any custom agent modes configured in the Cursor custom agent GUI per the Cursor docs."));
870
860
  }
871
861
  }
872
862
 
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "bmad-method",
3
- "version": "4.22.1",
3
+ "version": "4.24.0",
4
4
  "description": "BMAD Method installer - AI-powered Agile development framework",
5
5
  "main": "lib/installer.js",
6
6
  "bin": {
@@ -15,7 +15,7 @@ class DependencyResolver {
15
15
  const agentContent = await fs.readFile(agentPath, 'utf8');
16
16
 
17
17
  // Extract YAML from markdown content
18
- const yamlMatch = agentContent.match(/```ya?ml\n([\s\S]*?)\n```/);
18
+ const yamlMatch = agentContent.replace(/\r/g, "").match(/```ya?ml\n([\s\S]*?)\n```/);
19
19
  if (!yamlMatch) {
20
20
  throw new Error(`No YAML configuration found in agent ${agentId}`);
21
21
  }
@@ -191,4 +191,4 @@ class DependencyResolver {
191
191
  }
192
192
  }
193
193
 
194
- module.exports = DependencyResolver;
194
+ module.exports = DependencyResolver;