fix: include tools in codex artifacts
This commit is contained in:
parent
a23d5a52f9
commit
c0eccdaea8
|
|
@ -186,7 +186,9 @@ class CodexSetup extends BaseIdeSetup {
|
||||||
|
|
||||||
const taskToolGen = new TaskToolCommandGenerator();
|
const taskToolGen = new TaskToolCommandGenerator();
|
||||||
const taskManifest = await taskToolGen.loadTaskManifest(bmadDir);
|
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 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) {
|
for (const task of standaloneTasks) {
|
||||||
const content = taskToolGen.generateCommandContent(task, 'task');
|
const content = taskToolGen.generateCommandContent(task, 'task');
|
||||||
artifacts.push({
|
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 workflowGenerator = new WorkflowCommandGenerator(this.bmadFolderName);
|
||||||
const { artifacts: workflowArtifacts, counts: workflowCounts } = await workflowGenerator.collectWorkflowArtifacts(bmadDir);
|
const { artifacts: workflowArtifacts, counts: workflowCounts } = await workflowGenerator.collectWorkflowArtifacts(bmadDir);
|
||||||
artifacts.push(...workflowArtifacts);
|
artifacts.push(...workflowArtifacts);
|
||||||
|
|
@ -207,6 +220,7 @@ class CodexSetup extends BaseIdeSetup {
|
||||||
counts: {
|
counts: {
|
||||||
agents: agentArtifacts.length,
|
agents: agentArtifacts.length,
|
||||||
tasks: standaloneTasks.length,
|
tasks: standaloneTasks.length,
|
||||||
|
tools: standaloneTools.length,
|
||||||
workflows: workflowCounts.commands,
|
workflows: workflowCounts.commands,
|
||||||
workflowLaunchers: workflowCounts.launchers,
|
workflowLaunchers: workflowCounts.launchers,
|
||||||
},
|
},
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue