bmad-method 1.0.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.
- package/.bmad-core/agent-teams/team-all.yml +16 -0
- package/.bmad-core/agent-teams/team-fullstack.yml +26 -0
- package/.bmad-core/agent-teams/team-no-ui.yml +15 -0
- package/.bmad-core/agents/analyst.md +65 -0
- package/.bmad-core/agents/architect.md +66 -0
- package/.bmad-core/agents/bmad-master.md +107 -0
- package/.bmad-core/agents/bmad-orchestrator.md +81 -0
- package/.bmad-core/agents/dev.md +69 -0
- package/.bmad-core/agents/pm.md +64 -0
- package/.bmad-core/agents/po.md +60 -0
- package/.bmad-core/agents/qa.md +52 -0
- package/.bmad-core/agents/sm.md +60 -0
- package/.bmad-core/agents/ux-expert.md +66 -0
- package/.bmad-core/checklists/architect-checklist.md +443 -0
- package/.bmad-core/checklists/change-checklist.md +182 -0
- package/.bmad-core/checklists/pm-checklist.md +375 -0
- package/.bmad-core/checklists/po-master-checklist.md +441 -0
- package/.bmad-core/checklists/story-dod-checklist.md +101 -0
- package/.bmad-core/checklists/story-draft-checklist.md +156 -0
- package/.bmad-core/data/bmad-kb.md +36 -0
- package/.bmad-core/data/technical-preferences.md +3 -0
- package/.bmad-core/schemas/agent-team-schema.yml +153 -0
- package/.bmad-core/tasks/advanced-elicitation.md +92 -0
- package/.bmad-core/tasks/brainstorming-techniques.md +238 -0
- package/.bmad-core/tasks/brownfield-create-epic.md +160 -0
- package/.bmad-core/tasks/brownfield-create-story.md +147 -0
- package/.bmad-core/tasks/core-dump.md +74 -0
- package/.bmad-core/tasks/correct-course.md +73 -0
- package/.bmad-core/tasks/create-agent.md +202 -0
- package/.bmad-core/tasks/create-deep-research-prompt.md +301 -0
- package/.bmad-core/tasks/create-doc.md +74 -0
- package/.bmad-core/tasks/create-expansion-pack.md +425 -0
- package/.bmad-core/tasks/create-next-story.md +206 -0
- package/.bmad-core/tasks/create-team.md +229 -0
- package/.bmad-core/tasks/doc-migration-task.md +198 -0
- package/.bmad-core/tasks/execute-checklist.md +97 -0
- package/.bmad-core/tasks/generate-ai-frontend-prompt.md +58 -0
- package/.bmad-core/tasks/index-docs.md +180 -0
- package/.bmad-core/tasks/shard-doc.md +173 -0
- package/.bmad-core/templates/agent-tmpl.md +58 -0
- package/.bmad-core/templates/architecture-tmpl.md +771 -0
- package/.bmad-core/templates/brownfield-architecture-tmpl.md +542 -0
- package/.bmad-core/templates/brownfield-prd-tmpl.md +240 -0
- package/.bmad-core/templates/competitor-analysis-tmpl.md +289 -0
- package/.bmad-core/templates/expansion-pack-plan-tmpl.md +91 -0
- package/.bmad-core/templates/front-end-architecture-tmpl.md +173 -0
- package/.bmad-core/templates/front-end-spec-tmpl.md +411 -0
- package/.bmad-core/templates/fullstack-architecture-tmpl.md +1034 -0
- package/.bmad-core/templates/market-research-tmpl.md +261 -0
- package/.bmad-core/templates/prd-tmpl.md +200 -0
- package/.bmad-core/templates/project-brief-tmpl.md +228 -0
- package/.bmad-core/templates/story-tmpl.md +61 -0
- package/.bmad-core/templates/web-agent-startup-instructions-template.md +39 -0
- package/.bmad-core/utils/agent-switcher.ide.md +112 -0
- package/.bmad-core/utils/template-format.md +26 -0
- package/.bmad-core/utils/workflow-management.md +224 -0
- package/.bmad-core/web-bundles/agents/analyst.txt +1679 -0
- package/.bmad-core/web-bundles/agents/architect.txt +3602 -0
- package/.bmad-core/web-bundles/agents/bmad-master.txt +9496 -0
- package/.bmad-core/web-bundles/agents/bmad-orchestrator.txt +1455 -0
- package/.bmad-core/web-bundles/agents/dev.txt +315 -0
- package/.bmad-core/web-bundles/agents/pm.txt +2196 -0
- package/.bmad-core/web-bundles/agents/po.txt +1489 -0
- package/.bmad-core/web-bundles/agents/qa.txt +129 -0
- package/.bmad-core/web-bundles/agents/sm.txt +663 -0
- package/.bmad-core/web-bundles/agents/ux-expert.txt +1099 -0
- package/.bmad-core/web-bundles/teams/team-all.txt +10315 -0
- package/.bmad-core/web-bundles/teams/team-fullstack.txt +9663 -0
- package/.bmad-core/web-bundles/teams/team-no-ui.txt +8504 -0
- package/.bmad-core/workflows/brownfield-fullstack.yml +116 -0
- package/.bmad-core/workflows/brownfield-service.yml +117 -0
- package/.bmad-core/workflows/brownfield-ui.yml +127 -0
- package/.bmad-core/workflows/greenfield-fullstack.yml +177 -0
- package/.bmad-core/workflows/greenfield-service.yml +143 -0
- package/.bmad-core/workflows/greenfield-ui.yml +172 -0
- package/.claude/commands/analyst.md +69 -0
- package/.claude/commands/architect.md +70 -0
- package/.claude/commands/bmad-master.md +111 -0
- package/.claude/commands/bmad-orchestrator.md +85 -0
- package/.claude/commands/dev.md +73 -0
- package/.claude/commands/pm.md +68 -0
- package/.claude/commands/po.md +64 -0
- package/.claude/commands/qa.md +56 -0
- package/.claude/commands/sm.md +64 -0
- package/.claude/commands/ux-expert.md +70 -0
- package/.cursor/rules/analyst.mdc +83 -0
- package/.cursor/rules/architect.mdc +84 -0
- package/.cursor/rules/bmad-master.mdc +125 -0
- package/.cursor/rules/bmad-orchestrator.mdc +99 -0
- package/.cursor/rules/dev.mdc +87 -0
- package/.cursor/rules/pm.mdc +82 -0
- package/.cursor/rules/po.mdc +78 -0
- package/.cursor/rules/qa.mdc +70 -0
- package/.cursor/rules/sm.mdc +78 -0
- package/.cursor/rules/ux-expert.mdc +84 -0
- package/.github/workflows/release.yml +59 -0
- package/.husky/pre-commit +2 -0
- package/.releaserc.json +17 -0
- package/.roo/.roomodes +95 -0
- package/.roo/README.md +38 -0
- package/.vscode/extensions.json +6 -0
- package/.vscode/settings.json +72 -0
- package/.windsurf/rules/analyst.md +77 -0
- package/.windsurf/rules/architect.md +78 -0
- package/.windsurf/rules/bmad-master.md +119 -0
- package/.windsurf/rules/bmad-orchestrator.md +93 -0
- package/.windsurf/rules/dev.md +81 -0
- package/.windsurf/rules/pm.md +76 -0
- package/.windsurf/rules/po.md +72 -0
- package/.windsurf/rules/qa.md +64 -0
- package/.windsurf/rules/sm.md +72 -0
- package/.windsurf/rules/ux-expert.md +78 -0
- package/CHANGELOG.md +22 -0
- package/CONTRIBUTING.md +46 -0
- package/LICENSE +21 -0
- package/README.md +283 -0
- package/docs/versioning-and-releases.md +85 -0
- package/docs/versions.md +49 -0
- package/expansion-packs/README.md +113 -0
- package/expansion-packs/infrastructure-devops/README.md +147 -0
- package/expansion-packs/infrastructure-devops/agents/infra-devops-platform.md +59 -0
- package/expansion-packs/infrastructure-devops/checklists/infrastructure-checklist.md +484 -0
- package/expansion-packs/infrastructure-devops/manifest.yml +38 -0
- package/expansion-packs/infrastructure-devops/tasks/review-infrastructure.md +160 -0
- package/expansion-packs/infrastructure-devops/tasks/validate-infrastructure.md +154 -0
- package/expansion-packs/infrastructure-devops/templates/infrastructure-architecture-tmpl.md +415 -0
- package/expansion-packs/infrastructure-devops/templates/infrastructure-platform-from-arch-tmpl.md +0 -0
- package/package.json +73 -0
- package/tools/bmad-npx-wrapper.js +41 -0
- package/tools/builders/web-builder.js +145 -0
- package/tools/cli.js +119 -0
- package/tools/installer/README.md +58 -0
- package/tools/installer/bin/bmad.js +179 -0
- package/tools/installer/config/install.config.yml +139 -0
- package/tools/installer/lib/config-loader.js +89 -0
- package/tools/installer/lib/file-manager.js +169 -0
- package/tools/installer/lib/ide-setup.js +419 -0
- package/tools/installer/lib/installer.js +534 -0
- package/tools/installer/package-lock.json +704 -0
- package/tools/installer/package.json +43 -0
- package/tools/installer/templates/claude-commands.md +7 -0
- package/tools/installer/templates/cursor-rules.md +22 -0
- package/tools/installer/templates/windsurf-rules.md +22 -0
- package/tools/lib/dependency-resolver.js +179 -0
- package/tools/upgraders/v3-to-v4-upgrader.js +766 -0
- package/tools/version-bump.js +72 -0
- package/tools/yaml-format.js +211 -0
|
@@ -0,0 +1,145 @@
|
|
|
1
|
+
const fs = require('fs').promises;
|
|
2
|
+
const path = require('path');
|
|
3
|
+
const DependencyResolver = require('../lib/dependency-resolver');
|
|
4
|
+
|
|
5
|
+
class WebBuilder {
|
|
6
|
+
constructor(options = {}) {
|
|
7
|
+
this.rootDir = options.rootDir || process.cwd();
|
|
8
|
+
this.outputDirs = options.outputDirs || [
|
|
9
|
+
path.join(this.rootDir, 'dist'),
|
|
10
|
+
path.join(this.rootDir, '.bmad-core', 'web-bundles')
|
|
11
|
+
];
|
|
12
|
+
this.resolver = new DependencyResolver(this.rootDir);
|
|
13
|
+
this.templatePath = path.join(this.rootDir, '.bmad-core', 'templates', 'web-agent-startup-instructions-template.md');
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
async cleanOutputDirs() {
|
|
17
|
+
for (const dir of this.outputDirs) {
|
|
18
|
+
try {
|
|
19
|
+
await fs.rm(dir, { recursive: true, force: true });
|
|
20
|
+
console.log(`Cleaned: ${path.relative(this.rootDir, dir)}`);
|
|
21
|
+
} catch (error) {
|
|
22
|
+
// Directory might not exist, that's fine
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
async buildAgents() {
|
|
28
|
+
const agents = await this.resolver.listAgents();
|
|
29
|
+
|
|
30
|
+
for (const agentId of agents) {
|
|
31
|
+
console.log(` Building agent: ${agentId}`);
|
|
32
|
+
const bundle = await this.buildAgentBundle(agentId);
|
|
33
|
+
|
|
34
|
+
// Write to all output directories
|
|
35
|
+
for (const outputDir of this.outputDirs) {
|
|
36
|
+
const outputPath = path.join(outputDir, 'agents');
|
|
37
|
+
await fs.mkdir(outputPath, { recursive: true });
|
|
38
|
+
const outputFile = path.join(outputPath, `${agentId}.txt`);
|
|
39
|
+
await fs.writeFile(outputFile, bundle, 'utf8');
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
console.log(`Built ${agents.length} agent bundles in ${this.outputDirs.length} locations`);
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
async buildTeams() {
|
|
47
|
+
const teams = await this.resolver.listTeams();
|
|
48
|
+
|
|
49
|
+
for (const teamId of teams) {
|
|
50
|
+
console.log(` Building team: ${teamId}`);
|
|
51
|
+
const bundle = await this.buildTeamBundle(teamId);
|
|
52
|
+
|
|
53
|
+
// Write to all output directories
|
|
54
|
+
for (const outputDir of this.outputDirs) {
|
|
55
|
+
const outputPath = path.join(outputDir, 'teams');
|
|
56
|
+
await fs.mkdir(outputPath, { recursive: true });
|
|
57
|
+
const outputFile = path.join(outputPath, `${teamId}.txt`);
|
|
58
|
+
await fs.writeFile(outputFile, bundle, 'utf8');
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
console.log(`Built ${teams.length} team bundles in ${this.outputDirs.length} locations`);
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
async buildAgentBundle(agentId) {
|
|
66
|
+
const dependencies = await this.resolver.resolveAgentDependencies(agentId);
|
|
67
|
+
const template = await fs.readFile(this.templatePath, 'utf8');
|
|
68
|
+
|
|
69
|
+
const sections = [template];
|
|
70
|
+
|
|
71
|
+
// Add agent configuration
|
|
72
|
+
sections.push(this.formatSection(dependencies.agent.path, dependencies.agent.content));
|
|
73
|
+
|
|
74
|
+
// Add all dependencies
|
|
75
|
+
for (const resource of dependencies.resources) {
|
|
76
|
+
sections.push(this.formatSection(resource.path, resource.content));
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
return sections.join('\n');
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
async buildTeamBundle(teamId) {
|
|
83
|
+
const dependencies = await this.resolver.resolveTeamDependencies(teamId);
|
|
84
|
+
const template = await fs.readFile(this.templatePath, 'utf8');
|
|
85
|
+
|
|
86
|
+
const sections = [template];
|
|
87
|
+
|
|
88
|
+
// Add team configuration
|
|
89
|
+
sections.push(this.formatSection(dependencies.team.path, dependencies.team.content));
|
|
90
|
+
|
|
91
|
+
// Add all agents
|
|
92
|
+
for (const agent of dependencies.agents) {
|
|
93
|
+
sections.push(this.formatSection(agent.path, agent.content));
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
// Add all deduplicated resources
|
|
97
|
+
for (const resource of dependencies.resources) {
|
|
98
|
+
sections.push(this.formatSection(resource.path, resource.content));
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
return sections.join('\n');
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
formatSection(path, content) {
|
|
105
|
+
const separator = '====================';
|
|
106
|
+
return [
|
|
107
|
+
`${separator} START: ${path} ${separator}`,
|
|
108
|
+
content.trim(),
|
|
109
|
+
`${separator} END: ${path} ${separator}`,
|
|
110
|
+
''
|
|
111
|
+
].join('\n');
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
async validate() {
|
|
115
|
+
console.log('Validating agent configurations...');
|
|
116
|
+
const agents = await this.resolver.listAgents();
|
|
117
|
+
for (const agentId of agents) {
|
|
118
|
+
try {
|
|
119
|
+
await this.resolver.resolveAgentDependencies(agentId);
|
|
120
|
+
console.log(` ✓ ${agentId}`);
|
|
121
|
+
} catch (error) {
|
|
122
|
+
console.log(` ✗ ${agentId}: ${error.message}`);
|
|
123
|
+
throw error;
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
console.log('\nValidating team configurations...');
|
|
128
|
+
const teams = await this.resolver.listTeams();
|
|
129
|
+
for (const teamId of teams) {
|
|
130
|
+
try {
|
|
131
|
+
await this.resolver.resolveTeamDependencies(teamId);
|
|
132
|
+
console.log(` ✓ ${teamId}`);
|
|
133
|
+
} catch (error) {
|
|
134
|
+
console.log(` ✗ ${teamId}: ${error.message}`);
|
|
135
|
+
throw error;
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
listAgents() {
|
|
141
|
+
return this.resolver.listAgents();
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
module.exports = WebBuilder;
|
package/tools/cli.js
ADDED
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
const { Command } = require('commander');
|
|
4
|
+
const WebBuilder = require('./builders/web-builder');
|
|
5
|
+
const V3ToV4Upgrader = require('./upgraders/v3-to-v4-upgrader');
|
|
6
|
+
const IdeSetup = require('./installer/lib/ide-setup');
|
|
7
|
+
const path = require('path');
|
|
8
|
+
|
|
9
|
+
const program = new Command();
|
|
10
|
+
|
|
11
|
+
program
|
|
12
|
+
.name('bmad-build')
|
|
13
|
+
.description('BMAD-METHOD build tool for creating web bundles')
|
|
14
|
+
.version('4.0.0');
|
|
15
|
+
|
|
16
|
+
program
|
|
17
|
+
.command('build')
|
|
18
|
+
.description('Build web bundles for agents and teams')
|
|
19
|
+
.option('-a, --agents-only', 'Build only agent bundles')
|
|
20
|
+
.option('-t, --teams-only', 'Build only team bundles')
|
|
21
|
+
.option('--no-clean', 'Skip cleaning output directories')
|
|
22
|
+
.action(async (options) => {
|
|
23
|
+
const builder = new WebBuilder({
|
|
24
|
+
rootDir: process.cwd()
|
|
25
|
+
});
|
|
26
|
+
|
|
27
|
+
try {
|
|
28
|
+
if (options.clean) {
|
|
29
|
+
console.log('Cleaning output directories...');
|
|
30
|
+
await builder.cleanOutputDirs();
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
if (!options.teamsOnly) {
|
|
34
|
+
console.log('Building agent bundles...');
|
|
35
|
+
await builder.buildAgents();
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
if (!options.agentsOnly) {
|
|
39
|
+
console.log('Building team bundles...');
|
|
40
|
+
await builder.buildTeams();
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
// Generate IDE configuration folders
|
|
44
|
+
console.log('Generating IDE configuration folders...');
|
|
45
|
+
const installDir = process.cwd();
|
|
46
|
+
|
|
47
|
+
// Generate configurations for all supported IDEs
|
|
48
|
+
const ides = ['cursor', 'claude-code', 'windsurf', 'roo'];
|
|
49
|
+
for (const ide of ides) {
|
|
50
|
+
try {
|
|
51
|
+
console.log(`Setting up ${ide} integration...`);
|
|
52
|
+
await IdeSetup.setup(ide, installDir);
|
|
53
|
+
} catch (error) {
|
|
54
|
+
console.warn(`Warning: Failed to setup ${ide}:`, error.message);
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
console.log('Build completed successfully!');
|
|
59
|
+
} catch (error) {
|
|
60
|
+
console.error('Build failed:', error.message);
|
|
61
|
+
process.exit(1);
|
|
62
|
+
}
|
|
63
|
+
});
|
|
64
|
+
|
|
65
|
+
program
|
|
66
|
+
.command('list:agents')
|
|
67
|
+
.description('List all available agents')
|
|
68
|
+
.action(async () => {
|
|
69
|
+
const builder = new WebBuilder({ rootDir: process.cwd() });
|
|
70
|
+
const agents = await builder.resolver.listAgents();
|
|
71
|
+
console.log('Available agents:');
|
|
72
|
+
agents.forEach(agent => console.log(` - ${agent}`));
|
|
73
|
+
});
|
|
74
|
+
|
|
75
|
+
program
|
|
76
|
+
.command('validate')
|
|
77
|
+
.description('Validate agent and team configurations')
|
|
78
|
+
.action(async () => {
|
|
79
|
+
const builder = new WebBuilder({ rootDir: process.cwd() });
|
|
80
|
+
try {
|
|
81
|
+
// Validate by attempting to build all agents and teams
|
|
82
|
+
const agents = await builder.resolver.listAgents();
|
|
83
|
+
const teams = await builder.resolver.listTeams();
|
|
84
|
+
|
|
85
|
+
console.log('Validating agents...');
|
|
86
|
+
for (const agent of agents) {
|
|
87
|
+
await builder.resolver.resolveAgentDependencies(agent);
|
|
88
|
+
console.log(` ✓ ${agent}`);
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
console.log('\nValidating teams...');
|
|
92
|
+
for (const team of teams) {
|
|
93
|
+
await builder.resolver.resolveTeamDependencies(team);
|
|
94
|
+
console.log(` ✓ ${team}`);
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
console.log('\nAll configurations are valid!');
|
|
98
|
+
} catch (error) {
|
|
99
|
+
console.error('Validation failed:', error.message);
|
|
100
|
+
process.exit(1);
|
|
101
|
+
}
|
|
102
|
+
});
|
|
103
|
+
|
|
104
|
+
program
|
|
105
|
+
.command('upgrade')
|
|
106
|
+
.description('Upgrade a BMAD-METHOD V3 project to V4')
|
|
107
|
+
.option('-p, --project <path>', 'Path to V3 project (defaults to current directory)')
|
|
108
|
+
.option('--dry-run', 'Show what would be changed without making changes')
|
|
109
|
+
.option('--no-backup', 'Skip creating backup (not recommended)')
|
|
110
|
+
.action(async (options) => {
|
|
111
|
+
const upgrader = new V3ToV4Upgrader();
|
|
112
|
+
await upgrader.upgrade({
|
|
113
|
+
projectPath: options.project,
|
|
114
|
+
dryRun: options.dryRun,
|
|
115
|
+
backup: options.backup
|
|
116
|
+
});
|
|
117
|
+
});
|
|
118
|
+
|
|
119
|
+
program.parse();
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
# BMAD Method Installer
|
|
2
|
+
|
|
3
|
+
This directory contains the BMAD Method installer implementation.
|
|
4
|
+
|
|
5
|
+
## Structure
|
|
6
|
+
|
|
7
|
+
```text
|
|
8
|
+
installer/
|
|
9
|
+
├── bin/ # CLI entry points
|
|
10
|
+
│ └── bmad.js # Main CLI executable
|
|
11
|
+
├── lib/ # Core implementation
|
|
12
|
+
│ ├── installer.js # Main installation logic
|
|
13
|
+
│ ├── updater.js # Update management
|
|
14
|
+
│ ├── config-loader.js # YAML config parsing
|
|
15
|
+
│ ├── file-manager.js # File operations
|
|
16
|
+
│ ├── ide-setup.js # IDE-specific setup
|
|
17
|
+
│ └── prompts.js # Interactive CLI prompts
|
|
18
|
+
├── config/ # Configuration files
|
|
19
|
+
│ └── install.config.yml # Installation profiles
|
|
20
|
+
├── templates/ # IDE template files
|
|
21
|
+
│ ├── cursor-rules.md # Cursor template
|
|
22
|
+
│ ├── claude-commands.md # Claude Code template
|
|
23
|
+
│ └── windsurf-rules.md # Windsurf template
|
|
24
|
+
└── package.json # NPM package configuration
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
## Installation Profiles
|
|
28
|
+
|
|
29
|
+
- **minimal**: IDE agents only (best for beginners)
|
|
30
|
+
- **core**: IDE + Web agents
|
|
31
|
+
- **teams**: Full team workflows
|
|
32
|
+
- **developer**: Everything including creation tools
|
|
33
|
+
|
|
34
|
+
## Usage
|
|
35
|
+
|
|
36
|
+
````bash
|
|
37
|
+
# Interactive installation
|
|
38
|
+
npx bmad-method install
|
|
39
|
+
|
|
40
|
+
# Direct profile installation
|
|
41
|
+
npx bmad-method install --profile=minimal
|
|
42
|
+
|
|
43
|
+
# Update existing installation
|
|
44
|
+
npx bmad-method update
|
|
45
|
+
```text
|
|
46
|
+
|
|
47
|
+
## Development
|
|
48
|
+
|
|
49
|
+
```bash
|
|
50
|
+
# Install dependencies
|
|
51
|
+
npm install
|
|
52
|
+
|
|
53
|
+
# Run tests
|
|
54
|
+
npm test
|
|
55
|
+
|
|
56
|
+
# Lint code
|
|
57
|
+
npm run lint
|
|
58
|
+
````
|
|
@@ -0,0 +1,179 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
const { program } = require('commander');
|
|
4
|
+
const inquirer = require('inquirer');
|
|
5
|
+
const chalk = require('chalk');
|
|
6
|
+
const path = require('path');
|
|
7
|
+
|
|
8
|
+
// Handle both execution contexts (from root via npx or from installer directory)
|
|
9
|
+
let version, installer;
|
|
10
|
+
try {
|
|
11
|
+
// Try installer context first (when run from tools/installer/)
|
|
12
|
+
version = require('../package.json').version;
|
|
13
|
+
installer = require('../lib/installer');
|
|
14
|
+
} catch (e) {
|
|
15
|
+
// Fall back to root context (when run via npx from GitHub)
|
|
16
|
+
try {
|
|
17
|
+
version = require('../../../package.json').version;
|
|
18
|
+
installer = require('../../../tools/installer/lib/installer');
|
|
19
|
+
} catch (e2) {
|
|
20
|
+
console.error(chalk.red('Error: Could not load required modules. Please ensure you are running from the correct directory.'));
|
|
21
|
+
console.error(chalk.yellow('Debug info:'), {
|
|
22
|
+
__dirname,
|
|
23
|
+
cwd: process.cwd(),
|
|
24
|
+
error: e2.message
|
|
25
|
+
});
|
|
26
|
+
process.exit(1);
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
program
|
|
31
|
+
.version(version)
|
|
32
|
+
.description('BMAD Method installer - AI-powered Agile development framework');
|
|
33
|
+
|
|
34
|
+
program
|
|
35
|
+
.command('install')
|
|
36
|
+
.description('Install BMAD Method agents and tools')
|
|
37
|
+
.option('-f, --full', 'Install complete .bmad-core folder')
|
|
38
|
+
.option('-a, --agent <agent>', 'Install specific agent with dependencies')
|
|
39
|
+
.option('-d, --directory <path>', 'Installation directory (default: ./bmad-core)')
|
|
40
|
+
.option('-i, --ide <ide>', 'Configure for specific IDE (cursor, claude-code, windsurf, roo)')
|
|
41
|
+
.action(async (options) => {
|
|
42
|
+
try {
|
|
43
|
+
if (!options.full && !options.agent) {
|
|
44
|
+
// Interactive mode
|
|
45
|
+
const answers = await promptInstallation(options);
|
|
46
|
+
await installer.install(answers);
|
|
47
|
+
} else {
|
|
48
|
+
// Direct mode
|
|
49
|
+
const config = {
|
|
50
|
+
installType: options.full ? 'full' : 'single-agent',
|
|
51
|
+
agent: options.agent,
|
|
52
|
+
directory: options.directory || './.bmad-core',
|
|
53
|
+
ide: options.ide
|
|
54
|
+
};
|
|
55
|
+
await installer.install(config);
|
|
56
|
+
}
|
|
57
|
+
} catch (error) {
|
|
58
|
+
console.error(chalk.red('Installation failed:'), error.message);
|
|
59
|
+
process.exit(1);
|
|
60
|
+
}
|
|
61
|
+
});
|
|
62
|
+
|
|
63
|
+
program
|
|
64
|
+
.command('update')
|
|
65
|
+
.description('Update existing BMAD installation')
|
|
66
|
+
.option('--force', 'Force update, overwriting modified files')
|
|
67
|
+
.option('--dry-run', 'Show what would be updated without making changes')
|
|
68
|
+
.action(async (options) => {
|
|
69
|
+
try {
|
|
70
|
+
await installer.update(options);
|
|
71
|
+
} catch (error) {
|
|
72
|
+
console.error(chalk.red('Update failed:'), error.message);
|
|
73
|
+
process.exit(1);
|
|
74
|
+
}
|
|
75
|
+
});
|
|
76
|
+
|
|
77
|
+
program
|
|
78
|
+
.command('list')
|
|
79
|
+
.description('List available agents')
|
|
80
|
+
.action(async () => {
|
|
81
|
+
try {
|
|
82
|
+
await installer.listAgents();
|
|
83
|
+
} catch (error) {
|
|
84
|
+
console.error(chalk.red('Error:'), error.message);
|
|
85
|
+
process.exit(1);
|
|
86
|
+
}
|
|
87
|
+
});
|
|
88
|
+
|
|
89
|
+
program
|
|
90
|
+
.command('status')
|
|
91
|
+
.description('Show installation status')
|
|
92
|
+
.action(async () => {
|
|
93
|
+
try {
|
|
94
|
+
await installer.showStatus();
|
|
95
|
+
} catch (error) {
|
|
96
|
+
console.error(chalk.red('Error:'), error.message);
|
|
97
|
+
process.exit(1);
|
|
98
|
+
}
|
|
99
|
+
});
|
|
100
|
+
|
|
101
|
+
async function promptInstallation(options) {
|
|
102
|
+
console.log(chalk.bold.blue(`\nWelcome to BMAD Method Installer v${version}\n`));
|
|
103
|
+
|
|
104
|
+
const answers = {};
|
|
105
|
+
|
|
106
|
+
// Ask for installation directory
|
|
107
|
+
const { directory } = await inquirer.prompt([
|
|
108
|
+
{
|
|
109
|
+
type: 'input',
|
|
110
|
+
name: 'directory',
|
|
111
|
+
message: 'Where would you like to install BMAD?',
|
|
112
|
+
default: './.bmad-core'
|
|
113
|
+
}
|
|
114
|
+
]);
|
|
115
|
+
answers.directory = directory;
|
|
116
|
+
|
|
117
|
+
// Ask for installation type
|
|
118
|
+
const { installType } = await inquirer.prompt([
|
|
119
|
+
{
|
|
120
|
+
type: 'list',
|
|
121
|
+
name: 'installType',
|
|
122
|
+
message: 'How would you like to install BMAD?',
|
|
123
|
+
choices: [
|
|
124
|
+
{
|
|
125
|
+
name: 'Complete installation (recommended) - All agents and tools',
|
|
126
|
+
value: 'full'
|
|
127
|
+
},
|
|
128
|
+
{
|
|
129
|
+
name: 'Single agent - Choose one agent to install',
|
|
130
|
+
value: 'single-agent'
|
|
131
|
+
}
|
|
132
|
+
]
|
|
133
|
+
}
|
|
134
|
+
]);
|
|
135
|
+
answers.installType = installType;
|
|
136
|
+
|
|
137
|
+
// If single agent, ask which one
|
|
138
|
+
if (installType === 'single-agent') {
|
|
139
|
+
const agents = await installer.getAvailableAgents();
|
|
140
|
+
const { agent } = await inquirer.prompt([
|
|
141
|
+
{
|
|
142
|
+
type: 'list',
|
|
143
|
+
name: 'agent',
|
|
144
|
+
message: 'Select an agent to install:',
|
|
145
|
+
choices: agents.map(a => ({
|
|
146
|
+
name: `${a.id} - ${a.name} (${a.description})`,
|
|
147
|
+
value: a.id
|
|
148
|
+
}))
|
|
149
|
+
}
|
|
150
|
+
]);
|
|
151
|
+
answers.agent = agent;
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
// Ask for IDE configuration
|
|
155
|
+
const { ide } = await inquirer.prompt([
|
|
156
|
+
{
|
|
157
|
+
type: 'list',
|
|
158
|
+
name: 'ide',
|
|
159
|
+
message: 'Which IDE are you using?',
|
|
160
|
+
choices: [
|
|
161
|
+
{ name: 'Cursor', value: 'cursor' },
|
|
162
|
+
{ name: 'Claude Code', value: 'claude-code' },
|
|
163
|
+
{ name: 'Windsurf', value: 'windsurf' },
|
|
164
|
+
{ name: 'Roo Code', value: 'roo' },
|
|
165
|
+
{ name: 'Other/Manual setup', value: null }
|
|
166
|
+
]
|
|
167
|
+
}
|
|
168
|
+
]);
|
|
169
|
+
answers.ide = ide;
|
|
170
|
+
|
|
171
|
+
return answers;
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
program.parse(process.argv);
|
|
175
|
+
|
|
176
|
+
// Show help if no command provided
|
|
177
|
+
if (!process.argv.slice(2).length) {
|
|
178
|
+
program.outputHelp();
|
|
179
|
+
}
|
|
@@ -0,0 +1,139 @@
|
|
|
1
|
+
installation-options:
|
|
2
|
+
full:
|
|
3
|
+
name: Complete BMAD Core
|
|
4
|
+
description: Copy the entire .bmad-core folder with all agents, templates, and tools
|
|
5
|
+
action: copy-folder
|
|
6
|
+
source: .bmad-core
|
|
7
|
+
single-agent:
|
|
8
|
+
name: Single Agent
|
|
9
|
+
description: Select and install a single agent with its dependencies
|
|
10
|
+
action: copy-agent
|
|
11
|
+
agent-dependencies:
|
|
12
|
+
core-files:
|
|
13
|
+
- .bmad-core/utils/template-format.md
|
|
14
|
+
dev:
|
|
15
|
+
- .bmad-core/templates/story-tmpl.md
|
|
16
|
+
- .bmad-core/checklists/story-dod-checklist.md
|
|
17
|
+
pm:
|
|
18
|
+
- .bmad-core/templates/prd-tmpl.md
|
|
19
|
+
- .bmad-core/templates/brownfield-prd-tmpl.md
|
|
20
|
+
- .bmad-core/checklists/pm-checklist.md
|
|
21
|
+
- .bmad-core/checklists/change-checklist.md
|
|
22
|
+
- .bmad-core/tasks/advanced-elicitation.md
|
|
23
|
+
- .bmad-core/tasks/create-doc.md
|
|
24
|
+
- .bmad-core/tasks/correct-course.md
|
|
25
|
+
- .bmad-core/tasks/create-deep-research-prompt.md
|
|
26
|
+
- .bmad-core/tasks/brownfield-create-epic.md
|
|
27
|
+
- .bmad-core/tasks/brownfield-create-story.md
|
|
28
|
+
- .bmad-core/tasks/execute-checklist.md
|
|
29
|
+
- .bmad-core/tasks/shard-doc.md
|
|
30
|
+
architect:
|
|
31
|
+
- .bmad-core/templates/architecture-tmpl.md
|
|
32
|
+
- .bmad-core/checklists/architect-checklist.md
|
|
33
|
+
sm:
|
|
34
|
+
- .bmad-core/templates/story-tmpl.md
|
|
35
|
+
- .bmad-core/checklists/story-draft-checklist.md
|
|
36
|
+
- .bmad-core/workflows/*.yml
|
|
37
|
+
po:
|
|
38
|
+
- .bmad-core/checklists/po-master-checklist.md
|
|
39
|
+
- .bmad-core/templates/acceptance-criteria-tmpl.md
|
|
40
|
+
analyst:
|
|
41
|
+
- .bmad-core/templates/prd-tmpl.md
|
|
42
|
+
- .bmad-core/tasks/advanced-elicitation.md
|
|
43
|
+
qa:
|
|
44
|
+
- .bmad-core/checklists/story-dod-checklist.md
|
|
45
|
+
- .bmad-core/templates/test-plan-tmpl.md
|
|
46
|
+
ux-expert:
|
|
47
|
+
- .bmad-core/templates/ux-tmpl.md
|
|
48
|
+
bmad-master:
|
|
49
|
+
- .bmad-core/templates/*.md
|
|
50
|
+
- .bmad-core/tasks/*.md
|
|
51
|
+
- .bmad-core/schemas/*.yml
|
|
52
|
+
bmad-orchestrator:
|
|
53
|
+
- .bmad-core/agent-teams/*.yml
|
|
54
|
+
- .bmad-core/workflows/*.yml
|
|
55
|
+
ide-configurations:
|
|
56
|
+
cursor:
|
|
57
|
+
name: Cursor
|
|
58
|
+
rule-dir: .cursor/rules/
|
|
59
|
+
format: multi-file
|
|
60
|
+
command-suffix: .mdc
|
|
61
|
+
instructions: |
|
|
62
|
+
# To use BMAD agents in Cursor:
|
|
63
|
+
# 1. Press Ctrl+L (Cmd+L on Mac) to open the chat
|
|
64
|
+
# 2. Type @agent-name (e.g., "@dev", "@pm", "@architect")
|
|
65
|
+
# 3. The agent will adopt that persona for the conversation
|
|
66
|
+
claude-code:
|
|
67
|
+
name: Claude Code
|
|
68
|
+
rule-dir: .claude/commands/
|
|
69
|
+
format: multi-file
|
|
70
|
+
command-suffix: .md
|
|
71
|
+
instructions: |
|
|
72
|
+
# To use BMAD agents in Claude Code:
|
|
73
|
+
# 1. Type /agent-name (e.g., "/dev", "/pm", "/architect")
|
|
74
|
+
# 2. Claude will switch to that agent's persona
|
|
75
|
+
windsurf:
|
|
76
|
+
name: Windsurf
|
|
77
|
+
rule-dir: .windsurf/rules/
|
|
78
|
+
format: multi-file
|
|
79
|
+
command-suffix: .md
|
|
80
|
+
instructions: |
|
|
81
|
+
# To use BMAD agents in Windsurf:
|
|
82
|
+
# 1. Type @agent-name (e.g., "@dev", "@pm")
|
|
83
|
+
# 2. Windsurf will adopt that agent's persona
|
|
84
|
+
roo:
|
|
85
|
+
name: Roo Code
|
|
86
|
+
format: custom-modes
|
|
87
|
+
file: .roomodes
|
|
88
|
+
instructions: |
|
|
89
|
+
# To use BMAD agents in Roo Code:
|
|
90
|
+
# 1. Open the mode selector (usually in the status bar)
|
|
91
|
+
# 2. Select any bmad-{agent} mode (e.g., "bmad-dev", "bmad-pm")
|
|
92
|
+
# 3. The AI will adopt that agent's full personality and capabilities
|
|
93
|
+
cline:
|
|
94
|
+
name: Cline
|
|
95
|
+
format: unknown
|
|
96
|
+
instructions: |
|
|
97
|
+
# Cline configuration coming soon
|
|
98
|
+
# Manual setup: Copy IDE agent files to your Cline configuration
|
|
99
|
+
available-agents:
|
|
100
|
+
- id: analyst
|
|
101
|
+
name: Business Analyst
|
|
102
|
+
file: .bmad-core/agents/analyst.md
|
|
103
|
+
description: Requirements gathering and analysis
|
|
104
|
+
- id: pm
|
|
105
|
+
name: Product Manager
|
|
106
|
+
file: .bmad-core/agents/pm.md
|
|
107
|
+
description: Product strategy and roadmap planning
|
|
108
|
+
- id: architect
|
|
109
|
+
name: Solution Architect
|
|
110
|
+
file: .bmad-core/agents/architect.md
|
|
111
|
+
description: Technical design and architecture
|
|
112
|
+
- id: po
|
|
113
|
+
name: Product Owner
|
|
114
|
+
file: .bmad-core/agents/po.md
|
|
115
|
+
description: Backlog management and prioritization
|
|
116
|
+
- id: sm
|
|
117
|
+
name: Scrum Master
|
|
118
|
+
file: .bmad-core/agents/sm.md
|
|
119
|
+
description: Agile process and story creation
|
|
120
|
+
- id: dev
|
|
121
|
+
name: Developer
|
|
122
|
+
file: .bmad-core/agents/dev.md
|
|
123
|
+
description: Code implementation and testing
|
|
124
|
+
- id: qa
|
|
125
|
+
name: QA Engineer
|
|
126
|
+
file: .bmad-core/agents/qa.md
|
|
127
|
+
description: Quality assurance and testing
|
|
128
|
+
- id: ux-expert
|
|
129
|
+
name: UX Expert
|
|
130
|
+
file: .bmad-core/agents/ux-expert.md
|
|
131
|
+
description: User experience design
|
|
132
|
+
- id: bmad-master
|
|
133
|
+
name: BMAD Master
|
|
134
|
+
file: .bmad-core/agents/bmad-master.md
|
|
135
|
+
description: BMAD framework expert and guide
|
|
136
|
+
- id: bmad-orchestrator
|
|
137
|
+
name: BMAD Orchestrator
|
|
138
|
+
file: .bmad-core/agents/bmad-orchestrator.md
|
|
139
|
+
description: Multi-agent workflow coordinator
|