diff --git a/src/adapters/claude-code.ts b/src/adapters/claude-code.ts index 82187e0..5a31dcf 100644 --- a/src/adapters/claude-code.ts +++ b/src/adapters/claude-code.ts @@ -11,7 +11,7 @@ export async function injectClaudeCode(projectRoot: string): Promise { const commandDir = join(projectRoot, COMMANDS_DIR); await mkdir(commandDir, { recursive: true }); - const commandPath = join(commandDir, `${stage}.md`); + const commandPath = join(commandDir, `rune-${stage}.md`); if (!existsSync(commandPath)) { const cmd = hasChangeName ? `rune ${stage} <变更名>` diff --git a/tests/commands/init.test.ts b/tests/commands/init.test.ts index 887a947..1675300 100644 --- a/tests/commands/init.test.ts +++ b/tests/commands/init.test.ts @@ -41,7 +41,7 @@ describe("runInit", () => { it("注入 OpenCode command 和 skill", async () => { await runInit(TMP_DIR, ["opencode"]); - expect(existsSync(join(TMP_DIR, ".opencode", "commands", "discuss.md"))).toBe(true); + expect(existsSync(join(TMP_DIR, ".opencode", "commands", "rune-discuss.md"))).toBe(true); expect(existsSync(join(TMP_DIR, ".opencode", "skills", "rune-discuss.md"))).toBe(true); }); diff --git a/tests/integration/flow.test.ts b/tests/integration/flow.test.ts index a050546..ef46c45 100644 --- a/tests/integration/flow.test.ts +++ b/tests/integration/flow.test.ts @@ -26,7 +26,7 @@ describe("完整 SDD 流程", () => { it("init → discuss → plan → build → archive 完整流程", async () => { await runInit(TMP_DIR, ["opencode"]); expect(existsSync(join(TMP_DIR, ".rune", "config.yaml"))).toBe(true); - expect(existsSync(join(TMP_DIR, ".opencode", "commands", "discuss.md"))).toBe(true); + expect(existsSync(join(TMP_DIR, ".opencode", "commands", "rune-discuss.md"))).toBe(true); const config = await loadConfig(TMP_DIR); const discussPrompt = assembleDiscussPrompt(config);