Skip to content

fix: update src/core and src/bmm path references to match renamed directories#2053

Merged
bmadcode merged 2 commits intobmad-code-org:mainfrom
Sallvainian:fix/src-core-rename-mismatch
Mar 19, 2026
Merged

fix: update src/core and src/bmm path references to match renamed directories#2053
bmadcode merged 2 commits intobmad-code-org:mainfrom
Sallvainian:fix/src-core-rename-mismatch

Conversation

@Sallvainian
Copy link
Copy Markdown
Contributor

What

Update all installer CLI path references from src/core/src/bmm to src/core-skills/src/bmm-skills to match the v6.2.0 directory rename.

Why

The v6.2.0 release renamed these directories but the installer code wasn't updated, causing ENOENT crashes during installation.
Fixes #2052

How

  • Updated path references across 7 files in tools/cli/
  • Changed path.join() calls, string comparisons, regex patterns, and comments
  • No behavioral changes — purely aligning code with the actual directory structure

Testing

  • npm run validate:refs — 0 broken references
  • npm run test — all 232 tests pass, lint clean, format clean
  • Verified grep for old patterns returns 0 matches

…ectories

The v6.2.0 release renamed src/core to src/core-skills and src/bmm to
src/bmm-skills, but the installer CLI code still referenced the old
directory names, causing ENOENT crashes during installation.

Updated all path references across 7 files in tools/cli/ including
path.join() calls, string comparisons, regex patterns, and comments.

Fixes bmad-code-org#2052

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings March 18, 2026 08:54
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the installer CLI’s internal source-directory references to match the v6.2.0 repo rename from src/core/src/bmm to src/core-skills/src/bmm-skills, preventing ENOENT failures during installs.

Changes:

  • Updated source root detection and module path resolution to use core-skills / bmm-skills.
  • Updated installer/module-manager logic to locate built-in modules under the renamed directories.
  • Updated workflow/path normalization and module inference logic to reflect the new directory names.

Reviewed changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
tools/cli/lib/yaml-xml-builder.js Maps src/*-skills paths back to logical module ids (core/bmm) when inferring module from file path.
tools/cli/lib/project-root.js Uses src/core-skills as the project-root marker and updates built-in module path mapping.
tools/cli/installers/lib/modules/manager.js Points built-in bmm module discovery at src/bmm-skills and updates core special-casing to src/core-skills.
tools/cli/installers/lib/ide/shared/workflow-command-generator.js Updates workflow path transform rules to recognize src/*-skills locations.
tools/cli/installers/lib/core/manifest.js Loads core config from src/core-skills/config.yaml.
tools/cli/installers/lib/core/installer.js Updates core source scanning/lookup to src/core-skills.
tools/cli/installers/lib/core/dependency-resolver.js Updates dependency resolution’s source-structure handling to src/*-skills.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 633 to 641
// Check if file is in source directory structure
if (file.includes('/src/core/') || file.includes('/src/bmm/')) {
if (file.includes('/src/core-skills/') || file.includes('/src/bmm-skills/')) {
if (module === 'core') {
moduleBase = path.join(bmadDir, 'src', 'core');
moduleBase = path.join(bmadDir, 'src', 'core-skills');
} else if (module === 'bmm') {
moduleBase = path.join(bmadDir, 'src', 'bmm');
moduleBase = path.join(bmadDir, 'src', 'bmm-skills');
}
} else {
moduleBase = module === 'core' ? path.join(bmadDir, 'core') : path.join(bmadDir, 'modules', module);
Comment on lines +149 to 158
if (workflowPath.includes('/src/bmm-skills/')) {
const match = workflowPath.match(/\/src\/bmm-skills\/(.+)/);
if (match) {
transformed = `{project-root}/${this.bmadFolderName}/bmm/${match[1]}`;
}
} else if (workflowPath.includes('/src/core/')) {
const match = workflowPath.match(/\/src\/core\/(.+)/);
} else if (workflowPath.includes('/src/core-skills/')) {
const match = workflowPath.match(/\/src\/core-skills\/(.+)/);
if (match) {
transformed = `{project-root}/${this.bmadFolderName}/core/${match[1]}`;
}
@@ -251,7 +251,8 @@ class ModuleManager {
}

// Mark as custom if it's using custom.yaml OR if it's outside src/bmm or src/core
@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Mar 18, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 861108ab-169f-4193-a53c-06c601ce9d13

📥 Commits

Reviewing files that changed from the base of the PR and between be555aa and 905ccc9.

📒 Files selected for processing (7)
  • tools/cli/installers/lib/core/dependency-resolver.js
  • tools/cli/installers/lib/core/installer.js
  • tools/cli/installers/lib/core/manifest.js
  • tools/cli/installers/lib/ide/shared/workflow-command-generator.js
  • tools/cli/installers/lib/modules/manager.js
  • tools/cli/lib/project-root.js
  • tools/cli/lib/yaml-xml-builder.js

📝 Walkthrough

Walkthrough

Updates directory path references across CLI installer and project configuration modules from src/core to src/core-skills and src/bmm to src/bmm-skills to align with restructured module directories. Affects module discovery, dependency resolution, path lookups, and configuration loading.

Changes

Cohort / File(s) Summary
Core installer module
tools/cli/installers/lib/core/dependency-resolver.js, tools/cli/installers/lib/core/installer.js, tools/cli/installers/lib/core/manifest.js
Updated source directory path references: src/coresrc/core-skills, src/bmmsrc/bmm-skills in dependency collection, module path resolution, and configuration file lookups.
Module manager
tools/cli/installers/lib/modules/manager.js
Refactored built-in module location detection and path resolution to reference src/core-skills and src/bmm-skills instead of src/core and src/bmm across module discovery, info extraction, and directory creation.
Project configuration
tools/cli/lib/project-root.js, tools/cli/lib/yaml-xml-builder.js
Updated project root detection markers and module path resolution to use src/core-skills and src/bmm-skills; adjusted module detection logic to map these new paths to module identifiers.
IDE workflow generation
tools/cli/installers/lib/ide/shared/workflow-command-generator.js
Updated path transformation regex patterns to target src/bmm-skills/ and src/core-skills/ instead of src/bmm/ and src/core/.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~12 minutes

Suggested reviewers

  • bmadcode
  • alexeyv
  • muratkeremozcan
🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately summarizes the main change: updating path references from src/core and src/bmm to their renamed counterparts src/core-skills and src/bmm-skills.
Description check ✅ Passed The description clearly explains what was changed, why it was necessary (v6.2.0 directory rename causing ENOENT errors), how changes were made, and includes testing validation.
Linked Issues check ✅ Passed The PR successfully addresses issue #2052 by updating all path references from src/core/src/bmm to src/core-skills/src/bmm-skills across 7 files, directly resolving the ENOENT installation crashes.
Out of Scope Changes check ✅ Passed All changes are directly scoped to fixing the directory path references issue; no unrelated modifications detected across the 7 updated files.
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
📝 Coding Plan
  • Generate coding plan for human review comments

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Tip

You can validate your CodeRabbit configuration file in your editor.

If your editor has YAML language server, you can enable auto-completion and validation by adding # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json at the top of your CodeRabbit configuration file.

@bmadcode bmadcode merged commit 3c8d865 into bmad-code-org:main Mar 19, 2026
5 checks passed
@bmadcode
Copy link
Copy Markdown
Collaborator

Thanks @Sallvainian

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] Unable to install BMAD-METHOD for project

3 participants