diff --git a/tools/cli/installers/lib/ide/codex.js b/tools/cli/installers/lib/ide/codex.js index 7b4db59c..ee65f978 100644 --- a/tools/cli/installers/lib/ide/codex.js +++ b/tools/cli/installers/lib/ide/codex.js @@ -186,7 +186,9 @@ class CodexSetup extends BaseIdeSetup { const taskToolGen = new TaskToolCommandGenerator(); const taskManifest = await taskToolGen.loadTaskManifest(bmadDir); + const toolManifest = await taskToolGen.loadToolManifest(bmadDir); const standaloneTasks = taskManifest ? taskManifest.filter((task) => task.standalone === 'true' || task.standalone === true) : []; + const standaloneTools = toolManifest ? toolManifest.filter((tool) => tool.standalone === 'true' || tool.standalone === true) : []; for (const task of standaloneTasks) { const content = taskToolGen.generateCommandContent(task, 'task'); artifacts.push({ @@ -198,6 +200,17 @@ class CodexSetup extends BaseIdeSetup { }); } + for (const tool of standaloneTools) { + const content = taskToolGen.generateCommandContent(tool, 'tool'); + artifacts.push({ + type: 'tool', + module: tool.module, + sourcePath: tool.path, + relativePath: path.join(tool.module, 'tools', `${tool.name}.md`), + content, + }); + } + const workflowGenerator = new WorkflowCommandGenerator(this.bmadFolderName); const { artifacts: workflowArtifacts, counts: workflowCounts } = await workflowGenerator.collectWorkflowArtifacts(bmadDir); artifacts.push(...workflowArtifacts); @@ -207,6 +220,7 @@ class CodexSetup extends BaseIdeSetup { counts: { agents: agentArtifacts.length, tasks: standaloneTasks.length, + tools: standaloneTools.length, workflows: workflowCounts.commands, workflowLaunchers: workflowCounts.launchers, },