bmad-method 4.2.0 → 4.4.1

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 (176) hide show
  1. package/.claude/commands/analyst.md +14 -20
  2. package/.claude/commands/architect.md +15 -20
  3. package/.claude/commands/bmad-master.md +18 -26
  4. package/.claude/commands/bmad-orchestrator.md +80 -33
  5. package/.claude/commands/dev.md +5 -4
  6. package/.claude/commands/pm.md +11 -16
  7. package/.claude/commands/sm.md +20 -25
  8. package/.cursor/rules/analyst.mdc +13 -19
  9. package/.cursor/rules/architect.mdc +14 -19
  10. package/.cursor/rules/bmad-master.mdc +18 -26
  11. package/.cursor/rules/bmad-orchestrator.mdc +80 -33
  12. package/.cursor/rules/dev.mdc +5 -4
  13. package/.cursor/rules/pm.mdc +11 -16
  14. package/.cursor/rules/sm.mdc +19 -24
  15. package/.releaserc.json +2 -1
  16. package/.roo/README.md +0 -11
  17. package/.vscode/settings.json +4 -0
  18. package/.windsurf/rules/analyst.md +13 -19
  19. package/.windsurf/rules/architect.md +14 -19
  20. package/.windsurf/rules/bmad-master.md +18 -26
  21. package/.windsurf/rules/bmad-orchestrator.md +80 -33
  22. package/.windsurf/rules/dev.md +5 -4
  23. package/.windsurf/rules/pm.md +11 -16
  24. package/.windsurf/rules/sm.md +19 -24
  25. package/CHANGELOG.md +126 -2
  26. package/CONTRIBUTING.md +2 -0
  27. package/README.md +20 -2
  28. package/{.bmad-core → bmad-core}/agent-teams/team-all.yml +1 -3
  29. package/bmad-core/agent-teams/team-fullstack.yml +18 -0
  30. package/{.bmad-core → bmad-core}/agent-teams/team-no-ui.yml +0 -2
  31. package/{.bmad-core → bmad-core}/agents/analyst.md +14 -20
  32. package/{.bmad-core → bmad-core}/agents/architect.md +15 -20
  33. package/{.bmad-core → bmad-core}/agents/bmad-master.md +18 -26
  34. package/bmad-core/agents/bmad-orchestrator.md +128 -0
  35. package/{.bmad-core → bmad-core}/agents/dev.md +5 -4
  36. package/{.bmad-core → bmad-core}/agents/pm.md +11 -16
  37. package/{.bmad-core → bmad-core}/agents/qa.md +11 -17
  38. package/bmad-core/agents/sm.md +55 -0
  39. package/{.bmad-core → bmad-core}/agents/ux-expert.md +14 -20
  40. package/bmad-core/bmad-core-config.yml +60 -0
  41. package/bmad-core/data/bmad-kb.md +47 -0
  42. package/bmad-core/tasks/doc-migration-task.md +143 -0
  43. package/bmad-core/tasks/document-project.md +389 -0
  44. package/bmad-core/tasks/generate-ai-frontend-prompt.md +51 -0
  45. package/{.bmad-core → bmad-core}/tasks/index-docs.md +8 -3
  46. package/{.bmad-core → bmad-core}/tasks/shard-doc.md +5 -3
  47. package/{.bmad-core → bmad-core}/templates/architecture-tmpl.md +16 -13
  48. package/{.bmad-core → bmad-core}/templates/brownfield-architecture-tmpl.md +6 -6
  49. package/{.bmad-core → bmad-core}/templates/front-end-spec-tmpl.md +6 -6
  50. package/{.bmad-core → bmad-core}/templates/fullstack-architecture-tmpl.md +85 -103
  51. package/{.bmad-core → bmad-core}/templates/prd-tmpl.md +1 -1
  52. package/bmad-core/templates/simple-project-prd-tmpl.md +461 -0
  53. package/{.bmad-core → bmad-core}/templates/story-tmpl.md +2 -2
  54. package/{.bmad-core → bmad-core}/utils/agent-switcher.ide.md +6 -6
  55. package/{.bmad-core → bmad-core}/utils/workflow-management.md +14 -15
  56. package/{.bmad-core → bmad-core}/web-bundles/agents/analyst.txt +26 -21
  57. package/{.bmad-core → bmad-core}/web-bundles/agents/architect.txt +608 -236
  58. package/{.bmad-core → bmad-core}/web-bundles/agents/bmad-master.txt +467 -1049
  59. package/bmad-core/web-bundles/agents/bmad-orchestrator.txt +647 -0
  60. package/{.bmad-core → bmad-core}/web-bundles/agents/dev.txt +5 -4
  61. package/{.bmad-core → bmad-core}/web-bundles/agents/pm.txt +477 -18
  62. package/{.bmad-core → bmad-core}/web-bundles/agents/po.txt +3 -3
  63. package/{.bmad-core → bmad-core}/web-bundles/agents/qa.txt +11 -17
  64. package/{.bmad-core → bmad-core}/web-bundles/agents/sm.txt +22 -27
  65. package/{.bmad-core → bmad-core}/web-bundles/agents/ux-expert.txt +57 -70
  66. package/{.bmad-core → bmad-core}/workflows/greenfield-fullstack.yml +3 -3
  67. package/{.bmad-core → creator-tools}/tasks/create-agent.md +10 -12
  68. package/{.bmad-core/tasks/create-expansion-pack.md → creator-tools/tasks/generate-expansion-pack.md} +8 -6
  69. package/docs/bmad-workflow-guide.md +161 -0
  70. package/docs/claude-code-guide.md +119 -0
  71. package/docs/core-architecture.md +213 -0
  72. package/docs/cursor-guide.md +127 -0
  73. package/docs/how-to-contribute-with-pull-requests.md +141 -0
  74. package/docs/roo-code-guide.md +140 -0
  75. package/docs/user-guide.md +1044 -0
  76. package/docs/versioning-and-releases.md +4 -4
  77. package/docs/windsurf-guide.md +127 -0
  78. package/expansion-packs/README.md +1 -111
  79. package/expansion-packs/bmad-2d-phaser-game-dev/agent-teams/team-game-dev.yml +12 -0
  80. package/expansion-packs/bmad-2d-phaser-game-dev/agents/game-designer.md +58 -0
  81. package/expansion-packs/bmad-2d-phaser-game-dev/agents/game-developer.md +66 -0
  82. package/expansion-packs/bmad-2d-phaser-game-dev/agents/game-sm.md +51 -0
  83. package/expansion-packs/bmad-2d-phaser-game-dev/checklists/game-design-checklist.md +201 -0
  84. package/expansion-packs/bmad-2d-phaser-game-dev/checklists/game-story-dod-checklist.md +160 -0
  85. package/expansion-packs/bmad-2d-phaser-game-dev/data/bmad-kb.md +254 -0
  86. package/expansion-packs/bmad-2d-phaser-game-dev/data/development-guidelines.md +631 -0
  87. package/expansion-packs/bmad-2d-phaser-game-dev/manifest.yml +45 -0
  88. package/expansion-packs/bmad-2d-phaser-game-dev/tasks/advanced-elicitation.md +111 -0
  89. package/expansion-packs/bmad-2d-phaser-game-dev/tasks/create-game-story.md +216 -0
  90. package/expansion-packs/bmad-2d-phaser-game-dev/tasks/game-design-brainstorming.md +308 -0
  91. package/expansion-packs/bmad-2d-phaser-game-dev/templates/game-architecture-tmpl.md +560 -0
  92. package/expansion-packs/bmad-2d-phaser-game-dev/templates/game-brief-tmpl.md +345 -0
  93. package/expansion-packs/bmad-2d-phaser-game-dev/templates/game-design-doc-tmpl.md +331 -0
  94. package/expansion-packs/bmad-2d-phaser-game-dev/templates/game-story-tmpl.md +235 -0
  95. package/expansion-packs/bmad-2d-phaser-game-dev/templates/level-design-doc-tmpl.md +451 -0
  96. package/expansion-packs/bmad-2d-phaser-game-dev/web-bundles/agents/game-designer.txt +1758 -0
  97. package/expansion-packs/bmad-2d-phaser-game-dev/web-bundles/agents/game-developer.txt +1444 -0
  98. package/expansion-packs/bmad-2d-phaser-game-dev/web-bundles/agents/game-sm.txt +674 -0
  99. package/expansion-packs/bmad-2d-phaser-game-dev/web-bundles/team-game-dev.txt +4395 -0
  100. package/expansion-packs/bmad-2d-phaser-game-dev/web-bundles/teams/team-game-dev.txt +4395 -0
  101. package/expansion-packs/bmad-2d-phaser-game-dev/workflows/game-dev-greenfield.yml +183 -0
  102. package/expansion-packs/bmad-2d-phaser-game-dev/workflows/game-prototype.yml +175 -0
  103. package/expansion-packs/{infrastructure-devops → bmad-infrastructure-devops}/README.md +5 -5
  104. package/expansion-packs/{infrastructure-devops → bmad-infrastructure-devops}/agents/infra-devops-platform.md +3 -3
  105. package/expansion-packs/bmad-infrastructure-devops/manifest.yml +23 -0
  106. package/expansion-packs/bmad-infrastructure-devops/tasks/create-doc.md +74 -0
  107. package/expansion-packs/{infrastructure-devops → bmad-infrastructure-devops}/templates/infrastructure-platform-from-arch-tmpl.md +0 -0
  108. package/expansion-packs/bmad-infrastructure-devops/web-bundles/agents/infra-devops-platform.txt +2021 -0
  109. package/package.json +20 -14
  110. package/tools/builders/web-builder.js +207 -17
  111. package/tools/cli.js +55 -7
  112. package/tools/installer/README.md +2 -2
  113. package/tools/installer/bin/bmad.js +107 -28
  114. package/tools/installer/config/install.config.yml +43 -43
  115. package/tools/installer/lib/config-loader.js +39 -2
  116. package/tools/installer/lib/file-manager.js +20 -3
  117. package/tools/installer/lib/ide-setup.js +11 -1
  118. package/tools/installer/lib/installer.js +275 -29
  119. package/tools/installer/package-lock.json +538 -336
  120. package/tools/installer/package.json +8 -8
  121. package/tools/lib/dependency-resolver.js +2 -2
  122. package/tools/semantic-release-sync-installer.js +31 -0
  123. package/tools/sync-installer-version.js +34 -0
  124. package/tools/upgraders/v3-to-v4-upgrader.js +18 -13
  125. package/tools/version-bump.js +33 -26
  126. package/tools/yaml-format.js +54 -25
  127. package/.bmad-core/agent-teams/team-fullstack.yml +0 -26
  128. package/.bmad-core/agents/bmad-orchestrator.md +0 -81
  129. package/.bmad-core/agents/sm.md +0 -60
  130. package/.bmad-core/data/bmad-kb.md +0 -36
  131. package/.bmad-core/schemas/agent-team-schema.yml +0 -153
  132. package/.bmad-core/tasks/create-team.md +0 -229
  133. package/.bmad-core/tasks/doc-migration-task.md +0 -198
  134. package/.bmad-core/tasks/generate-ai-frontend-prompt.md +0 -58
  135. package/.bmad-core/web-bundles/agents/bmad-orchestrator.txt +0 -1455
  136. package/.bmad-core/web-bundles/teams/team-all.txt +0 -10315
  137. package/.bmad-core/web-bundles/teams/team-fullstack.txt +0 -9663
  138. package/.bmad-core/web-bundles/teams/team-no-ui.txt +0 -8504
  139. package/.claude/settings.local.json +0 -22
  140. package/expansion-packs/infrastructure-devops/manifest.yml +0 -38
  141. /package/{.bmad-core → bmad-core}/agents/po.md +0 -0
  142. /package/{.bmad-core → bmad-core}/checklists/architect-checklist.md +0 -0
  143. /package/{.bmad-core → bmad-core}/checklists/change-checklist.md +0 -0
  144. /package/{.bmad-core → bmad-core}/checklists/pm-checklist.md +0 -0
  145. /package/{.bmad-core → bmad-core}/checklists/po-master-checklist.md +0 -0
  146. /package/{.bmad-core → bmad-core}/checklists/story-dod-checklist.md +0 -0
  147. /package/{.bmad-core → bmad-core}/checklists/story-draft-checklist.md +0 -0
  148. /package/{.bmad-core → bmad-core}/data/technical-preferences.md +0 -0
  149. /package/{.bmad-core → bmad-core}/tasks/advanced-elicitation.md +0 -0
  150. /package/{.bmad-core → bmad-core}/tasks/brainstorming-techniques.md +0 -0
  151. /package/{.bmad-core → bmad-core}/tasks/brownfield-create-epic.md +0 -0
  152. /package/{.bmad-core → bmad-core}/tasks/brownfield-create-story.md +0 -0
  153. /package/{.bmad-core → bmad-core}/tasks/core-dump.md +0 -0
  154. /package/{.bmad-core → bmad-core}/tasks/correct-course.md +0 -0
  155. /package/{.bmad-core → bmad-core}/tasks/create-deep-research-prompt.md +0 -0
  156. /package/{.bmad-core → bmad-core}/tasks/create-doc.md +0 -0
  157. /package/{.bmad-core → bmad-core}/tasks/create-next-story.md +0 -0
  158. /package/{.bmad-core → bmad-core}/tasks/execute-checklist.md +0 -0
  159. /package/{.bmad-core → bmad-core}/templates/agent-tmpl.md +0 -0
  160. /package/{.bmad-core → bmad-core}/templates/brownfield-prd-tmpl.md +0 -0
  161. /package/{.bmad-core → bmad-core}/templates/competitor-analysis-tmpl.md +0 -0
  162. /package/{.bmad-core → bmad-core}/templates/expansion-pack-plan-tmpl.md +0 -0
  163. /package/{.bmad-core → bmad-core}/templates/front-end-architecture-tmpl.md +0 -0
  164. /package/{.bmad-core → bmad-core}/templates/market-research-tmpl.md +0 -0
  165. /package/{.bmad-core → bmad-core}/templates/project-brief-tmpl.md +0 -0
  166. /package/{.bmad-core → bmad-core}/templates/web-agent-startup-instructions-template.md +0 -0
  167. /package/{.bmad-core → bmad-core}/utils/template-format.md +0 -0
  168. /package/{.bmad-core → bmad-core}/workflows/brownfield-fullstack.yml +0 -0
  169. /package/{.bmad-core → bmad-core}/workflows/brownfield-service.yml +0 -0
  170. /package/{.bmad-core → bmad-core}/workflows/brownfield-ui.yml +0 -0
  171. /package/{.bmad-core → bmad-core}/workflows/greenfield-service.yml +0 -0
  172. /package/{.bmad-core → bmad-core}/workflows/greenfield-ui.yml +0 -0
  173. /package/expansion-packs/{infrastructure-devops → bmad-infrastructure-devops}/checklists/infrastructure-checklist.md +0 -0
  174. /package/expansion-packs/{infrastructure-devops → bmad-infrastructure-devops}/tasks/review-infrastructure.md +0 -0
  175. /package/expansion-packs/{infrastructure-devops → bmad-infrastructure-devops}/tasks/validate-infrastructure.md +0 -0
  176. /package/expansion-packs/{infrastructure-devops → bmad-infrastructure-devops}/templates/infrastructure-architecture-tmpl.md +0 -0
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "bmad-method",
3
- "version": "4.0.0",
3
+ "version": "4.4.1",
4
4
  "description": "BMAD Method installer - AI-powered Agile development framework",
5
5
  "main": "lib/installer.js",
6
6
  "bin": {
@@ -22,15 +22,15 @@
22
22
  "author": "BMAD Team",
23
23
  "license": "MIT",
24
24
  "dependencies": {
25
- "chalk": "^4.1.2",
26
- "commander": "^9.4.1",
27
- "fs-extra": "^11.1.0",
28
- "inquirer": "^8.2.5",
25
+ "chalk": "^5.4.1",
26
+ "commander": "^14.0.0",
27
+ "fs-extra": "^11.3.0",
28
+ "inquirer": "^12.6.3",
29
29
  "js-yaml": "^4.1.0",
30
- "ora": "^5.4.1"
30
+ "ora": "^8.2.0"
31
31
  },
32
32
  "engines": {
33
- "node": ">=14.0.0"
33
+ "node": ">=20.0.0"
34
34
  },
35
35
  "repository": {
36
36
  "type": "git",
@@ -40,4 +40,4 @@
40
40
  "url": "https://github.com/bmad-team/bmad-method/issues"
41
41
  },
42
42
  "homepage": "https://github.com/bmad-team/bmad-method#readme"
43
- }
43
+ }
@@ -5,7 +5,7 @@ const yaml = require('js-yaml');
5
5
  class DependencyResolver {
6
6
  constructor(rootDir) {
7
7
  this.rootDir = rootDir;
8
- this.bmadCore = path.join(rootDir, '.bmad-core');
8
+ this.bmadCore = path.join(rootDir, 'bmad-core');
9
9
  this.cache = new Map();
10
10
  }
11
11
 
@@ -14,7 +14,7 @@ class DependencyResolver {
14
14
  const agentContent = await fs.readFile(agentPath, 'utf8');
15
15
 
16
16
  // Extract YAML from markdown content
17
- const yamlMatch = agentContent.match(/```yml\n([\s\S]*?)\n```/);
17
+ const yamlMatch = agentContent.match(/```ya?ml\n([\s\S]*?)\n```/);
18
18
  if (!yamlMatch) {
19
19
  throw new Error(`No YAML configuration found in agent ${agentId}`);
20
20
  }
@@ -0,0 +1,31 @@
1
+ /**
2
+ * Semantic-release plugin to sync installer package.json version
3
+ */
4
+
5
+ const fs = require('fs');
6
+ const path = require('path');
7
+
8
+ function prepare(pluginConfig, context) {
9
+ const { nextRelease, logger } = context;
10
+
11
+ // Path to installer package.json
12
+ const installerPackagePath = path.join(process.cwd(), 'tools', 'installer', 'package.json');
13
+
14
+ if (!fs.existsSync(installerPackagePath)) {
15
+ logger.log('Installer package.json not found, skipping sync');
16
+ return;
17
+ }
18
+
19
+ // Read installer package.json
20
+ const installerPackage = JSON.parse(fs.readFileSync(installerPackagePath, 'utf8'));
21
+
22
+ // Update version
23
+ installerPackage.version = nextRelease.version;
24
+
25
+ // Write back
26
+ fs.writeFileSync(installerPackagePath, JSON.stringify(installerPackage, null, 2) + '\n');
27
+
28
+ logger.log(`Synced installer package.json to version ${nextRelease.version}`);
29
+ }
30
+
31
+ module.exports = { prepare };
@@ -0,0 +1,34 @@
1
+ #!/usr/bin/env node
2
+
3
+ /**
4
+ * Sync installer package.json version with main package.json
5
+ * Used by semantic-release to keep versions in sync
6
+ */
7
+
8
+ const fs = require('fs');
9
+ const path = require('path');
10
+
11
+ function syncInstallerVersion() {
12
+ // Read main package.json
13
+ const mainPackagePath = path.join(__dirname, '..', 'package.json');
14
+ const mainPackage = JSON.parse(fs.readFileSync(mainPackagePath, 'utf8'));
15
+
16
+ // Read installer package.json
17
+ const installerPackagePath = path.join(__dirname, 'installer', 'package.json');
18
+ const installerPackage = JSON.parse(fs.readFileSync(installerPackagePath, 'utf8'));
19
+
20
+ // Update installer version to match main version
21
+ installerPackage.version = mainPackage.version;
22
+
23
+ // Write back installer package.json
24
+ fs.writeFileSync(installerPackagePath, JSON.stringify(installerPackage, null, 2) + '\n');
25
+
26
+ console.log(`Synced installer version to ${mainPackage.version}`);
27
+ }
28
+
29
+ // Run if called directly
30
+ if (require.main === module) {
31
+ syncInstallerVersion();
32
+ }
33
+
34
+ module.exports = { syncInstallerVersion };
@@ -1,11 +1,16 @@
1
1
  const fs = require("fs").promises;
2
2
  const path = require("path");
3
- const chalk = require("chalk");
4
- const ora = require("ora");
5
- const glob = require("glob");
6
- const inquirer = require("inquirer");
7
- const { promisify } = require("util");
8
- const globAsync = promisify(glob);
3
+ const { glob } = require("glob");
4
+
5
+ // Dynamic imports for ES modules
6
+ let chalk, ora, inquirer;
7
+
8
+ // Initialize ES modules
9
+ async function initializeModules() {
10
+ chalk = (await import("chalk")).default;
11
+ ora = (await import("ora")).default;
12
+ inquirer = (await import("inquirer")).default;
13
+ }
9
14
 
10
15
  class V3ToV4Upgrader {
11
16
  constructor() {
@@ -14,6 +19,8 @@ class V3ToV4Upgrader {
14
19
 
15
20
  async upgrade(options = {}) {
16
21
  try {
22
+ // Initialize ES modules
23
+ await initializeModules();
17
24
  // Keep readline open throughout the process
18
25
  process.stdin.resume();
19
26
 
@@ -233,17 +240,17 @@ class V3ToV4Upgrader {
233
240
  }
234
241
 
235
242
  // Find epic files
236
- const epicFiles = await globAsync("epic*.md", { cwd: docsPath });
243
+ const epicFiles = await glob("epic*.md", { cwd: docsPath });
237
244
 
238
245
  // Find story files
239
246
  const storiesPath = path.join(docsPath, "stories");
240
247
  let storyFiles = [];
241
248
  if (await this.pathExists(storiesPath)) {
242
- storyFiles = await globAsync("*.md", { cwd: storiesPath });
249
+ storyFiles = await glob("*.md", { cwd: storiesPath });
243
250
  }
244
251
 
245
252
  // Count custom files in bmad-agent
246
- const bmadAgentFiles = await globAsync("**/*.md", {
253
+ const bmadAgentFiles = await glob("**/*.md", {
247
254
  cwd: bmadAgentPath,
248
255
  ignore: ["node_modules/**"],
249
256
  });
@@ -738,13 +745,11 @@ class V3ToV4Upgrader {
738
745
 
739
746
  async createInstallManifest(projectPath) {
740
747
  const fileManager = require("../installer/lib/file-manager");
741
- const glob = require("glob");
742
- const { promisify } = require("util");
743
- const globAsync = promisify(glob);
748
+ const { glob } = require("glob");
744
749
 
745
750
  // Get all files in .bmad-core for the manifest
746
751
  const bmadCorePath = path.join(projectPath, ".bmad-core");
747
- const files = await globAsync("**/*", {
752
+ const files = await glob("**/*", {
748
753
  cwd: bmadCorePath,
749
754
  nodir: true,
750
755
  ignore: ["**/.git/**", "**/node_modules/**"],
@@ -2,7 +2,17 @@
2
2
 
3
3
  const fs = require('fs');
4
4
  const { execSync } = require('child_process');
5
- const chalk = require('chalk');
5
+ const path = require('path');
6
+
7
+ // Dynamic import for ES module
8
+ let chalk;
9
+
10
+ // Initialize ES modules
11
+ async function initializeModules() {
12
+ if (!chalk) {
13
+ chalk = (await import('chalk')).default;
14
+ }
15
+ }
6
16
 
7
17
  /**
8
18
  * Simple version bumping script for BMAD-METHOD
@@ -14,38 +24,32 @@ function getCurrentVersion() {
14
24
  return packageJson.version;
15
25
  }
16
26
 
17
- function bumpVersion(type = 'patch') {
27
+ async function bumpVersion(type = 'patch') {
28
+ await initializeModules();
29
+
18
30
  const validTypes = ['patch', 'minor', 'major'];
19
31
  if (!validTypes.includes(type)) {
20
32
  console.error(chalk.red(`Invalid version type: ${type}. Use: ${validTypes.join(', ')}`));
21
33
  process.exit(1);
22
34
  }
23
35
 
24
- console.log(chalk.blue(`🔄 Bumping ${type} version...`));
36
+ console.log(chalk.yellow('⚠️ Manual version bumping is disabled.'));
37
+ console.log(chalk.blue('🤖 This project uses semantic-release for automated versioning.'));
38
+ console.log('');
39
+ console.log(chalk.bold('To create a new release, use conventional commits:'));
40
+ console.log(chalk.cyan(' feat: new feature (minor version bump)'));
41
+ console.log(chalk.cyan(' fix: bug fix (patch version bump)'));
42
+ console.log(chalk.cyan(' feat!: breaking change (major version bump)'));
43
+ console.log('');
44
+ console.log(chalk.dim('Example: git commit -m "feat: add new installer features"'));
45
+ console.log(chalk.dim('Then push to main branch to trigger automatic release.'));
25
46
 
26
- // Use npm version to bump and create git tag
27
- try {
28
- const newVersion = execSync(`npm version ${type} --no-git-tag-version`, { encoding: 'utf8' }).trim();
29
- console.log(chalk.green(`✅ Version bumped to ${newVersion}`));
30
-
31
- // Stage the package.json change
32
- execSync('git add package.json');
33
-
34
- // Create commit and tag
35
- execSync(`git commit -m "chore: bump version to ${newVersion}"`);
36
- execSync(`git tag -a ${newVersion} -m "Release ${newVersion}"`);
37
-
38
- console.log(chalk.green(`✅ Created git tag: ${newVersion}`));
39
- console.log(chalk.yellow(`💡 Run 'git push && git push --tags' to publish`));
40
-
41
- return newVersion;
42
- } catch (error) {
43
- console.error(chalk.red('❌ Version bump failed:'), error.message);
44
- process.exit(1);
45
- }
47
+ return null;
46
48
  }
47
49
 
48
- function main() {
50
+ async function main() {
51
+ await initializeModules();
52
+
49
53
  const type = process.argv[2] || 'patch';
50
54
  const currentVersion = getCurrentVersion();
51
55
 
@@ -59,14 +63,17 @@ function main() {
59
63
  process.exit(1);
60
64
  }
61
65
 
62
- const newVersion = bumpVersion(type);
66
+ const newVersion = await bumpVersion(type);
63
67
 
64
68
  console.log(chalk.green(`\n🎉 Version bump complete!`));
65
69
  console.log(chalk.blue(`📦 ${currentVersion} → ${newVersion}`));
66
70
  }
67
71
 
68
72
  if (require.main === module) {
69
- main();
73
+ main().catch(error => {
74
+ console.error('Error:', error);
75
+ process.exit(1);
76
+ });
70
77
  }
71
78
 
72
79
  module.exports = { bumpVersion, getCurrentVersion };
@@ -4,14 +4,24 @@ const fs = require('fs');
4
4
  const path = require('path');
5
5
  const yaml = require('js-yaml');
6
6
  const { execSync } = require('child_process');
7
- const chalk = require('chalk');
7
+
8
+ // Dynamic import for ES module
9
+ let chalk;
10
+
11
+ // Initialize ES modules
12
+ async function initializeModules() {
13
+ if (!chalk) {
14
+ chalk = (await import('chalk')).default;
15
+ }
16
+ }
8
17
 
9
18
  /**
10
19
  * YAML Formatter and Linter for BMAD-METHOD
11
20
  * Formats and validates YAML files and YAML embedded in Markdown
12
21
  */
13
22
 
14
- function formatYamlContent(content, filename) {
23
+ async function formatYamlContent(content, filename) {
24
+ await initializeModules();
15
25
  try {
16
26
  // First try to fix common YAML issues
17
27
  let fixedContent = content
@@ -62,7 +72,8 @@ function formatYamlContent(content, filename) {
62
72
  }
63
73
  }
64
74
 
65
- function processMarkdownFile(filePath) {
75
+ async function processMarkdownFile(filePath) {
76
+ await initializeModules();
66
77
  const content = fs.readFileSync(filePath, 'utf8');
67
78
  let modified = false;
68
79
  let newContent = content;
@@ -77,22 +88,34 @@ function processMarkdownFile(filePath) {
77
88
 
78
89
  // Find YAML code blocks
79
90
  const yamlBlockRegex = /```ya?ml\n([\s\S]*?)\n```/g;
91
+ let match;
92
+ const replacements = [];
80
93
 
81
- newContent = newContent.replace(yamlBlockRegex, (match, yamlContent) => {
82
- const formatted = formatYamlContent(yamlContent, filePath);
83
- if (formatted === null) {
84
- return match; // Keep original if parsing failed
85
- }
86
-
87
- // Remove trailing newline that js-yaml adds
88
- const trimmedFormatted = formatted.replace(/\n$/, '');
89
-
90
- if (trimmedFormatted !== yamlContent) {
91
- modified = true;
94
+ while ((match = yamlBlockRegex.exec(newContent)) !== null) {
95
+ const [fullMatch, yamlContent] = match;
96
+ const formatted = await formatYamlContent(yamlContent, filePath);
97
+ if (formatted !== null) {
98
+ // Remove trailing newline that js-yaml adds
99
+ const trimmedFormatted = formatted.replace(/\n$/, '');
100
+
101
+ if (trimmedFormatted !== yamlContent) {
102
+ modified = true;
103
+ console.log(chalk.green(`✓ Formatted YAML in ${filePath}`));
104
+ }
105
+
106
+ replacements.push({
107
+ start: match.index,
108
+ end: match.index + fullMatch.length,
109
+ replacement: `\`\`\`yaml\n${trimmedFormatted}\n\`\`\``
110
+ });
92
111
  }
93
-
94
- return `\`\`\`yml\n${trimmedFormatted}\n\`\`\``;
95
- });
112
+ }
113
+
114
+ // Apply replacements in reverse order to maintain indices
115
+ for (let i = replacements.length - 1; i >= 0; i--) {
116
+ const { start, end, replacement } = replacements[i];
117
+ newContent = newContent.slice(0, start) + replacement + newContent.slice(end);
118
+ }
96
119
 
97
120
  if (modified) {
98
121
  fs.writeFileSync(filePath, newContent);
@@ -101,9 +124,10 @@ function processMarkdownFile(filePath) {
101
124
  return false;
102
125
  }
103
126
 
104
- function processYamlFile(filePath) {
127
+ async function processYamlFile(filePath) {
128
+ await initializeModules();
105
129
  const content = fs.readFileSync(filePath, 'utf8');
106
- const formatted = formatYamlContent(content, filePath);
130
+ const formatted = await formatYamlContent(content, filePath);
107
131
 
108
132
  if (formatted === null) {
109
133
  return false; // Syntax error
@@ -116,7 +140,8 @@ function processYamlFile(filePath) {
116
140
  return false;
117
141
  }
118
142
 
119
- function lintYamlFile(filePath) {
143
+ async function lintYamlFile(filePath) {
144
+ await initializeModules();
120
145
  try {
121
146
  // Use yaml-lint for additional validation
122
147
  execSync(`npx yaml-lint "${filePath}"`, { stdio: 'pipe' });
@@ -128,7 +153,8 @@ function lintYamlFile(filePath) {
128
153
  }
129
154
  }
130
155
 
131
- function main() {
156
+ async function main() {
157
+ await initializeModules();
132
158
  const args = process.argv.slice(2);
133
159
  const glob = require('glob');
134
160
 
@@ -170,13 +196,13 @@ function main() {
170
196
  try {
171
197
  let changed = false;
172
198
  if (ext === '.md') {
173
- changed = processMarkdownFile(filePath);
199
+ changed = await processMarkdownFile(filePath);
174
200
  } else if (ext === '.yml' || ext === '.yaml' || basename.includes('roomodes') || basename.includes('.yml') || basename.includes('.yaml')) {
175
201
  // Handle YAML files and special cases like .roomodes
176
- changed = processYamlFile(filePath);
202
+ changed = await processYamlFile(filePath);
177
203
 
178
204
  // Also run linting
179
- const lintPassed = lintYamlFile(filePath);
205
+ const lintPassed = await lintYamlFile(filePath);
180
206
  if (!lintPassed) hasErrors = true;
181
207
  } else {
182
208
  // Skip silently for unsupported files
@@ -205,7 +231,10 @@ function main() {
205
231
  }
206
232
 
207
233
  if (require.main === module) {
208
- main();
234
+ main().catch(error => {
235
+ console.error('Error:', error);
236
+ process.exit(1);
237
+ });
209
238
  }
210
239
 
211
240
  module.exports = { formatYamlContent, processMarkdownFile, processYamlFile };
@@ -1,26 +0,0 @@
1
- bundle:
2
- name: Team Fullstack
3
- icon: 🚀
4
- description: >-
5
- Comprehensive full-stack development team capable of handling both greenfield
6
- application development and brownfield enhancement projects. This team combines
7
- strategic planning, user experience design, and holistic system architecture
8
- to deliver complete solutions from concept to deployment. Specializes in
9
- full-stack applications, SaaS platforms, enterprise apps, feature additions,
10
- refactoring, and system modernization.
11
-
12
- agents:
13
- - bmad-orchestrator
14
- - analyst
15
- - pm
16
- - ux-expert
17
- - architect
18
- - po
19
-
20
- workflows:
21
- - brownfield-fullstack
22
- - brownfield-service
23
- - brownfield-ui
24
- - greenfield-fullstack
25
- - greenfield-service
26
- - greenfield-ui
@@ -1,81 +0,0 @@
1
- # bmad
2
-
3
- CRITICAL: Read the full YML to understand your operating params, start activation to alter your state of being, follow startup instructions, stay in this being until told to exit this mode:
4
-
5
- ```yml
6
- agent:
7
- name: BMad Orchestrator
8
- id: bmad-orchestrator
9
- title: BMAD Master Orchestrator
10
- icon: 🎭
11
- whenToUse: "Use for workflow coordination, multi-agent tasks, role switching guidance, and when unsure which specialist to consult"
12
-
13
- persona:
14
- role: Master Orchestrator & BMAD Method Expert
15
- style: Knowledgeable, guiding, adaptable, efficient, encouraging, technically brilliant yet approachable. Helps customize and use BMAD Method while orchestrating agents
16
- identity: Unified interface to all BMAD-METHOD capabilities, dynamically transforms into any specialized agent
17
- focus: Orchestrating the right agent/capability for each need, loading resources only when needed
18
-
19
- core_principles:
20
- - Become any agent on demand, loading files only when needed
21
- - Never pre-load resources - discover and load at runtime
22
- - Assess needs and recommend best approach/agent/workflow
23
- - Track current state and guide to next logical steps
24
- - When embodied, specialized persona's principles take precedence
25
- - Be explicit about active persona and current task
26
- - Always use numbered lists for choices
27
- - Process (*) commands immediately
28
-
29
- startup:
30
- - Announce: "Hey! I'm BMad, your BMAD-METHOD orchestrator. I can become any specialized agent, suggest workflows, explain setup, or help with any BMAD task. Type *help for options."
31
- - Assess user goal, suggest agent transformation if match, offer numbered options if generic
32
- - Load resources only when needed
33
-
34
- commands:
35
- - "*help" - Show commands/workflows/agents
36
- - "*chat-mode" - Conversational mode with advanced-elicitation
37
- - "*kb-mode" - Load knowledge base for full BMAD help
38
- - "*status" - Show current context/agent/progress
39
- - "*agent {name}" - Transform into agent (list if unspecified)
40
- - "*exit" - Return to BMad or exit (confirm if exiting BMad)
41
- - "*task {name}" - Run task (list if unspecified)
42
- - "*workflow {type}" - Start/list workflows
43
- - "*checklist {name}" - Execute checklist (list if unspecified)
44
- - "*yolo" - Toggle skip confirmations
45
- - "*party-mode" - Group chat with all agents
46
- - "*doc-out" - Output full document
47
-
48
- fuzzy-matching:
49
- - 85% confidence threshold
50
- - Show numbered list if unsure
51
-
52
- transformation:
53
- - Match name/role to agents
54
- - Announce transformation
55
- - Operate until exit
56
-
57
- loading:
58
- - KB: Only for *kb-mode or BMAD questions
59
- - Agents: Only when transforming
60
- - Templates/Tasks: Only when executing
61
- - Always indicate loading
62
-
63
- workflow:
64
- - Ask project type (greenfield/brownfield)
65
- - Ask scope (UI/service/fullstack/other)
66
- - Recommend workflow, guide through stages
67
- - Explain web context management if needed
68
-
69
- dependencies:
70
- tasks:
71
- - create-agent
72
- - create-team
73
- - create-expansion-pack
74
- - advanced-elicitation
75
- - create-doc
76
- data:
77
- - bmad-kb
78
- utils:
79
- - workflow-management
80
- - template-format
81
- ```
@@ -1,60 +0,0 @@
1
- # sm
2
-
3
- CRITICAL: Read the full YML, start activation to alter your state of being, follow startup section instructions, stay in this being until told to exit this mode:
4
-
5
- ```yml
6
- activation-instructions:
7
- - Follow all instructions in this file -> this defines you, your persona and more importantly what you can do. STAY IN CHARACTER!
8
- - Only read the files/tasks listed here when user selects them for execution to minimize context usage
9
- - The customization field ALWAYS takes precedence over any conflicting instructions
10
- - When listing tasks/templates or presenting options during conversations, always show as numbered options list, allowing the user to type a number to select or execute
11
-
12
- agent:
13
- name: Bob
14
- id: sm
15
- title: Scrum Master
16
- icon: 🏃
17
- whenToUse: "Use for story creation, epic management, retrospectives in party-mode, and agile process guidance"
18
- customization:
19
-
20
- persona:
21
- role: Technical Scrum Master - Story Preparation Specialist
22
- style: Task-oriented, efficient, precise, focused on clear developer handoffs
23
- identity: Story creation expert who prepares detailed, actionable stories for AI developers
24
- focus: Creating crystal-clear stories that dumb AI agents can implement without confusion
25
-
26
- core_principles:
27
- - Task Adherence - Rigorously follow create-next-story procedures
28
- - Checklist-Driven Validation - Apply story-draft-checklist meticulously
29
- - Clarity for Developer Handoff - Stories must be immediately actionable
30
- - Focus on One Story at a Time - Complete one before starting next
31
- - Numbered Options Protocol - Always use numbered lists for selections
32
-
33
- startup:
34
- - Greet the user with your name and role, and inform of the *help command.
35
- - Confirm with user if they wish to prepare the next story for development
36
- - If yes, execute all steps in Create Next Story Task document
37
- - If no, await instructions offering Scrum Master assistance
38
- - CRITICAL RULE: You are ONLY allowed to create/modify story files - NEVER implement! If asked to implement, tell user they MUST switch to Dev Agent
39
-
40
- commands:
41
- - "*help" - Show: numbered list of the following commands to allow selection
42
- - "*chat-mode" - Conversational mode with advanced-elicitation for advice
43
- - "*create" - Execute all steps in Create Next Story Task document
44
- - "*pivot" - Run correct-course task (ensure no story already created first)
45
- - "*checklist {checklist}" - Show numbered list of checklists, execute selection
46
- - "*doc-shard {PRD|Architecture|Other}" - Execute shard-doc task
47
- - "*index-docs" - Update documentation index in /docs/index.md
48
- - "*exit" - Say goodbye as the Scrum Master, and then abandon inhabiting this persona
49
-
50
- dependencies:
51
- tasks:
52
- - create-next-story
53
- - execute-checklist
54
- templates:
55
- - story-tmpl
56
- checklists:
57
- - story-draft-checklist
58
- utils:
59
- - template-format
60
- ```
@@ -1,36 +0,0 @@
1
- # BMAD Knowledge Base
2
-
3
- ## Overview
4
-
5
- BMAD-METHOD (Breakthrough Method of Agile AI-driven Development) is a framework that combines AI agents with Agile development methodologies. The v4 system introduces a modular architecture with improved dependency management, bundle optimization, and support for both web and IDE environments.
6
-
7
- ### Key Features
8
-
9
- - **Modular Agent System**: Specialized AI agents for each Agile role
10
- - **Build System**: Automated dependency resolution and optimization
11
- - **Dual Environment Support**: Optimized for both web UIs and IDEs
12
- - **Reusable Resources**: Portable templates, tasks, and checklists
13
- - **Slash Command Integration**: Quick agent switching and control
14
-
15
- ## Core Philosophy
16
-
17
- ### Vibe CEO'ing
18
-
19
- You are the "Vibe CEO" - thinking like a CEO with unlimited resources and a singular vision. Your AI agents are your high-powered team, and your role is to:
20
-
21
- - **Direct**: Provide clear instructions and objectives
22
- - **Refine**: Iterate on outputs to achieve quality
23
- - **Oversee**: Maintain strategic alignment across all agents
24
-
25
- ### Core Principles
26
-
27
- 1. **MAXIMIZE_AI_LEVERAGE**: Push the AI to deliver more. Challenge outputs and iterate.
28
- 2. **QUALITY_CONTROL**: You are the ultimate arbiter of quality. Review all outputs.
29
- 3. **STRATEGIC_OVERSIGHT**: Maintain the high-level vision and ensure alignment.
30
- 4. **ITERATIVE_REFINEMENT**: Expect to revisit steps. This is not a linear process.
31
- 5. **CLEAR_INSTRUCTIONS**: Precise requests lead to better outputs.
32
- 6. **DOCUMENTATION_IS_KEY**: Good inputs (briefs, PRDs) lead to good outputs.
33
- 7. **START_SMALL_SCALE_FAST**: Test concepts, then expand.
34
- 8. **EMBRACE_THE_CHAOS**: Adapt and overcome challenges.
35
-
36
- ## TODO: ADD MORE CONTENT ONCE STABLE ALPHA BUILD