bmad_folder replacement working properly with custom and defauly modules
This commit is contained in:
parent
86f2786dde
commit
9d7b09d065
|
|
@ -853,8 +853,13 @@ class ModuleManager {
|
|||
// Compile with customizations if any
|
||||
const { xml } = compileAgent(yamlContent, {}, agentName, relativePath, { config: this.coreConfig });
|
||||
|
||||
// Write the compiled MD file
|
||||
await fs.writeFile(targetMdPath, xml, 'utf8');
|
||||
// Replace {bmad_folder} placeholder if needed
|
||||
if (xml.includes('{bmad_folder}') && this.bmadFolderName) {
|
||||
const processedXml = xml.replaceAll('{bmad_folder}', this.bmadFolderName);
|
||||
await fs.writeFile(targetMdPath, processedXml, 'utf8');
|
||||
} else {
|
||||
await fs.writeFile(targetMdPath, xml, 'utf8');
|
||||
}
|
||||
|
||||
// Copy sidecar files if agent has hasSidecar flag
|
||||
if (hasSidecar) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue