feat: claude-code command 文件加 rune- 前缀

This commit is contained in:
2026-06-08 18:38:48 +08:00
parent 97d64e48db
commit 4ea60f7679
3 changed files with 3 additions and 3 deletions

View File

@@ -11,7 +11,7 @@ export async function injectClaudeCode(projectRoot: string): Promise<void> {
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} <变更名>`

View File

@@ -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);
});

View File

@@ -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);