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,72 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
const fs = require('fs');
|
|
4
|
+
const { execSync } = require('child_process');
|
|
5
|
+
const chalk = require('chalk');
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* Simple version bumping script for BMAD-METHOD
|
|
9
|
+
* Usage: node tools/version-bump.js [patch|minor|major]
|
|
10
|
+
*/
|
|
11
|
+
|
|
12
|
+
function getCurrentVersion() {
|
|
13
|
+
const packageJson = JSON.parse(fs.readFileSync('package.json', 'utf8'));
|
|
14
|
+
return packageJson.version;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
function bumpVersion(type = 'patch') {
|
|
18
|
+
const validTypes = ['patch', 'minor', 'major'];
|
|
19
|
+
if (!validTypes.includes(type)) {
|
|
20
|
+
console.error(chalk.red(`Invalid version type: ${type}. Use: ${validTypes.join(', ')}`));
|
|
21
|
+
process.exit(1);
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
console.log(chalk.blue(`š Bumping ${type} version...`));
|
|
25
|
+
|
|
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
|
+
}
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
function main() {
|
|
49
|
+
const type = process.argv[2] || 'patch';
|
|
50
|
+
const currentVersion = getCurrentVersion();
|
|
51
|
+
|
|
52
|
+
console.log(chalk.blue(`Current version: ${currentVersion}`));
|
|
53
|
+
|
|
54
|
+
// Check if working directory is clean
|
|
55
|
+
try {
|
|
56
|
+
execSync('git diff-index --quiet HEAD --');
|
|
57
|
+
} catch (error) {
|
|
58
|
+
console.error(chalk.red('ā Working directory is not clean. Commit your changes first.'));
|
|
59
|
+
process.exit(1);
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
const newVersion = bumpVersion(type);
|
|
63
|
+
|
|
64
|
+
console.log(chalk.green(`\nš Version bump complete!`));
|
|
65
|
+
console.log(chalk.blue(`š¦ ${currentVersion} ā ${newVersion}`));
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
if (require.main === module) {
|
|
69
|
+
main();
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
module.exports = { bumpVersion, getCurrentVersion };
|
|
@@ -0,0 +1,211 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
const fs = require('fs');
|
|
4
|
+
const path = require('path');
|
|
5
|
+
const yaml = require('js-yaml');
|
|
6
|
+
const { execSync } = require('child_process');
|
|
7
|
+
const chalk = require('chalk');
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* YAML Formatter and Linter for BMAD-METHOD
|
|
11
|
+
* Formats and validates YAML files and YAML embedded in Markdown
|
|
12
|
+
*/
|
|
13
|
+
|
|
14
|
+
function formatYamlContent(content, filename) {
|
|
15
|
+
try {
|
|
16
|
+
// First try to fix common YAML issues
|
|
17
|
+
let fixedContent = content
|
|
18
|
+
// Fix "commands :" -> "commands:"
|
|
19
|
+
.replace(/^(\s*)(\w+)\s+:/gm, '$1$2:')
|
|
20
|
+
// Fix inconsistent list indentation
|
|
21
|
+
.replace(/^(\s*)-\s{3,}/gm, '$1- ');
|
|
22
|
+
|
|
23
|
+
// Skip auto-fixing for .roomodes files - they have special nested structure
|
|
24
|
+
if (!filename.includes('.roomodes')) {
|
|
25
|
+
fixedContent = fixedContent
|
|
26
|
+
// Fix unquoted list items that contain special characters or multiple parts
|
|
27
|
+
.replace(/^(\s*)-\s+(.*)$/gm, (match, indent, content) => {
|
|
28
|
+
// Skip if already quoted
|
|
29
|
+
if (content.startsWith('"') && content.endsWith('"')) {
|
|
30
|
+
return match;
|
|
31
|
+
}
|
|
32
|
+
// If the content contains special YAML characters or looks complex, quote it
|
|
33
|
+
// BUT skip if it looks like a proper YAML key-value pair (like "key: value")
|
|
34
|
+
if ((content.includes(':') || content.includes('-') || content.includes('{') || content.includes('}')) &&
|
|
35
|
+
!content.match(/^\w+:\s/)) {
|
|
36
|
+
// Remove any existing quotes first, escape internal quotes, then add proper quotes
|
|
37
|
+
const cleanContent = content.replace(/^["']|["']$/g, '').replace(/"/g, '\\"');
|
|
38
|
+
return `${indent}- "${cleanContent}"`;
|
|
39
|
+
}
|
|
40
|
+
return match;
|
|
41
|
+
});
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
// Debug: show what we're trying to parse
|
|
45
|
+
if (fixedContent !== content) {
|
|
46
|
+
console.log(chalk.blue(`š§ Applied YAML fixes to ${filename}`));
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
// Parse and re-dump YAML to format it
|
|
50
|
+
const parsed = yaml.load(fixedContent);
|
|
51
|
+
const formatted = yaml.dump(parsed, {
|
|
52
|
+
indent: 2,
|
|
53
|
+
lineWidth: -1, // Disable line wrapping
|
|
54
|
+
noRefs: true,
|
|
55
|
+
sortKeys: false // Preserve key order
|
|
56
|
+
});
|
|
57
|
+
return formatted;
|
|
58
|
+
} catch (error) {
|
|
59
|
+
console.error(chalk.red(`ā YAML syntax error in ${filename}:`), error.message);
|
|
60
|
+
console.error(chalk.yellow(`š” Try manually fixing the YAML structure first`));
|
|
61
|
+
return null;
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
function processMarkdownFile(filePath) {
|
|
66
|
+
const content = fs.readFileSync(filePath, 'utf8');
|
|
67
|
+
let modified = false;
|
|
68
|
+
let newContent = content;
|
|
69
|
+
|
|
70
|
+
// Fix untyped code blocks by adding 'text' type
|
|
71
|
+
// Match ``` at start of line followed by newline, but only if it's an opening fence
|
|
72
|
+
newContent = newContent.replace(/^```\n([\s\S]*?)\n```$/gm, '```text\n$1\n```');
|
|
73
|
+
if (newContent !== content) {
|
|
74
|
+
modified = true;
|
|
75
|
+
console.log(chalk.blue(`š§ Added 'text' type to untyped code blocks in ${filePath}`));
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
// Find YAML code blocks
|
|
79
|
+
const yamlBlockRegex = /```ya?ml\n([\s\S]*?)\n```/g;
|
|
80
|
+
|
|
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;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
return `\`\`\`yml\n${trimmedFormatted}\n\`\`\``;
|
|
95
|
+
});
|
|
96
|
+
|
|
97
|
+
if (modified) {
|
|
98
|
+
fs.writeFileSync(filePath, newContent);
|
|
99
|
+
return true;
|
|
100
|
+
}
|
|
101
|
+
return false;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
function processYamlFile(filePath) {
|
|
105
|
+
const content = fs.readFileSync(filePath, 'utf8');
|
|
106
|
+
const formatted = formatYamlContent(content, filePath);
|
|
107
|
+
|
|
108
|
+
if (formatted === null) {
|
|
109
|
+
return false; // Syntax error
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
if (formatted !== content) {
|
|
113
|
+
fs.writeFileSync(filePath, formatted);
|
|
114
|
+
return true;
|
|
115
|
+
}
|
|
116
|
+
return false;
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
function lintYamlFile(filePath) {
|
|
120
|
+
try {
|
|
121
|
+
// Use yaml-lint for additional validation
|
|
122
|
+
execSync(`npx yaml-lint "${filePath}"`, { stdio: 'pipe' });
|
|
123
|
+
return true;
|
|
124
|
+
} catch (error) {
|
|
125
|
+
console.error(chalk.red(`ā YAML lint error in ${filePath}:`));
|
|
126
|
+
console.error(error.stdout?.toString() || error.message);
|
|
127
|
+
return false;
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
function main() {
|
|
132
|
+
const args = process.argv.slice(2);
|
|
133
|
+
const glob = require('glob');
|
|
134
|
+
|
|
135
|
+
if (args.length === 0) {
|
|
136
|
+
console.error('Usage: node yaml-format.js <file1> [file2] ...');
|
|
137
|
+
process.exit(1);
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
let hasErrors = false;
|
|
141
|
+
let hasChanges = false;
|
|
142
|
+
let filesProcessed = [];
|
|
143
|
+
|
|
144
|
+
// Expand glob patterns and collect all files
|
|
145
|
+
const allFiles = [];
|
|
146
|
+
for (const arg of args) {
|
|
147
|
+
if (arg.includes('*')) {
|
|
148
|
+
// It's a glob pattern
|
|
149
|
+
const matches = glob.sync(arg);
|
|
150
|
+
allFiles.push(...matches);
|
|
151
|
+
} else {
|
|
152
|
+
// It's a direct file path
|
|
153
|
+
allFiles.push(arg);
|
|
154
|
+
}
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
for (const filePath of allFiles) {
|
|
158
|
+
if (!fs.existsSync(filePath)) {
|
|
159
|
+
// Skip silently for glob patterns that don't match anything
|
|
160
|
+
if (!args.some(arg => arg.includes('*') && filePath === arg)) {
|
|
161
|
+
console.error(chalk.red(`ā File not found: ${filePath}`));
|
|
162
|
+
hasErrors = true;
|
|
163
|
+
}
|
|
164
|
+
continue;
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
const ext = path.extname(filePath).toLowerCase();
|
|
168
|
+
const basename = path.basename(filePath).toLowerCase();
|
|
169
|
+
|
|
170
|
+
try {
|
|
171
|
+
let changed = false;
|
|
172
|
+
if (ext === '.md') {
|
|
173
|
+
changed = processMarkdownFile(filePath);
|
|
174
|
+
} else if (ext === '.yml' || ext === '.yaml' || basename.includes('roomodes') || basename.includes('.yml') || basename.includes('.yaml')) {
|
|
175
|
+
// Handle YAML files and special cases like .roomodes
|
|
176
|
+
changed = processYamlFile(filePath);
|
|
177
|
+
|
|
178
|
+
// Also run linting
|
|
179
|
+
const lintPassed = lintYamlFile(filePath);
|
|
180
|
+
if (!lintPassed) hasErrors = true;
|
|
181
|
+
} else {
|
|
182
|
+
// Skip silently for unsupported files
|
|
183
|
+
continue;
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
if (changed) {
|
|
187
|
+
hasChanges = true;
|
|
188
|
+
filesProcessed.push(filePath);
|
|
189
|
+
}
|
|
190
|
+
} catch (error) {
|
|
191
|
+
console.error(chalk.red(`ā Error processing ${filePath}:`), error.message);
|
|
192
|
+
hasErrors = true;
|
|
193
|
+
}
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
if (hasChanges) {
|
|
197
|
+
console.log(chalk.green(`\n⨠YAML formatting completed! Modified ${filesProcessed.length} files:`));
|
|
198
|
+
filesProcessed.forEach(file => console.log(chalk.blue(` š ${file}`)));
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
if (hasErrors) {
|
|
202
|
+
console.error(chalk.red('\nš„ Some files had errors. Please fix them before committing.'));
|
|
203
|
+
process.exit(1);
|
|
204
|
+
}
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
if (require.main === module) {
|
|
208
|
+
main();
|
|
209
|
+
}
|
|
210
|
+
|
|
211
|
+
module.exports = { formatYamlContent, processMarkdownFile, processYamlFile };
|