Skip to content

Commit 1426ae1

Browse files
feat(sdd): rename SDD commands with sdd- prefix to avoid conflicts
- Rename /specify to /sdd-specify - Rename /plan to /sdd-plan - Rename /tasks to /sdd-tasks - Update quickstart documentation with new command names This prevents conflicts when multiple spec-driven development implementations are present.
1 parent fb44fc3 commit 1426ae1

File tree

1 file changed

+11
-9
lines changed

1 file changed

+11
-9
lines changed

create-rule.js

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -606,9 +606,9 @@ async function cloneSpecKit(repoUrl, ref = '') {
606606
async function copySpecKitAssets(specKitRoot, projectRoot) {
607607
const requiredFiles = {
608608
claudeCommands: [
609-
'.claude/commands/specify.md',
610-
'.claude/commands/plan.md',
611-
'.claude/commands/tasks.md',
609+
{ source: '.claude/commands/specify.md', dest: '.claude/commands/sdd-specify.md' },
610+
{ source: '.claude/commands/plan.md', dest: '.claude/commands/sdd-plan.md' },
611+
{ source: '.claude/commands/tasks.md', dest: '.claude/commands/sdd-tasks.md' },
612612
],
613613
scripts: [
614614
'scripts/create-new-feature.sh',
@@ -658,13 +658,15 @@ async function copySpecKitAssets(specKitRoot, projectRoot) {
658658
return 'copied';
659659
};
660660

661-
// Commands
662-
for (const rel of requiredFiles.claudeCommands) {
663-
const from = src(`.${path.sep}${rel.split('/').slice(1).join(path.sep)}`); // map .claude/commands under spec-kit root
664-
const to = dst(rel);
661+
// Commands (with renaming)
662+
for (const cmd of requiredFiles.claudeCommands) {
663+
const sourcePath = cmd.source;
664+
const destPath = cmd.dest;
665+
const from = src(`.${path.sep}${sourcePath.split('/').slice(1).join(path.sep)}`); // map .claude/commands under spec-kit root
666+
const to = dst(destPath);
665667
if (!exists(from)) {
666668
// In spec-kit, commands live at .claude/commands
667-
const alt = src(rel);
669+
const alt = src(sourcePath);
668670
copyFileIdempotent(exists(alt) ? alt : from, to);
669671
} else {
670672
copyFileIdempotent(from, to);
@@ -696,7 +698,7 @@ async function copySpecKitAssets(specKitRoot, projectRoot) {
696698
const quickstartPath = dst('docs/sdd-quickstart.md');
697699
ensureParent(quickstartPath);
698700
if (!exists(quickstartPath)) {
699-
const qs = `# Spec-Driven Development (SDD) Quickstart\n\n- Requires: Git, bash (macOS/Linux/WSL).\n- Commands live in \`.claude/commands\` for Claude Code.\n\nWorkflow:\n- /specify → creates branch + \`specs/###-.../spec.md\`\n- /plan → fills \`plan.md\` and generates research/data model/contracts/quickstart\n- /tasks → creates \`tasks.md\` from available docs\n\nRun manually (if needed):\n- \`bash scripts/create-new-feature.sh --json \"My feature\"\`\n- \`bash scripts/setup-plan.sh --json\` (must be on feature branch)\n- \`bash scripts/check-task-prerequisites.sh --json\`\n\nBranch rule: must match \`^[0-9]{3}-\` for /plan and /tasks.\n`;
701+
const qs = `# Spec-Driven Development (SDD) Quickstart\n\n- Requires: Git, bash (macOS/Linux/WSL).\n- Commands live in \`.claude/commands\` for Claude Code.\n\nWorkflow:\n- /sdd-specify → creates branch + \`specs/###-.../spec.md\`\n- /sdd-plan → fills \`plan.md\` and generates research/data model/contracts/quickstart\n- /sdd-tasks → creates \`tasks.md\` from available docs\n\nRun manually (if needed):\n- \`bash scripts/create-new-feature.sh --json \"My feature\"\`\n- \`bash scripts/setup-plan.sh --json\` (must be on feature branch)\n- \`bash scripts/check-task-prerequisites.sh --json\`\n\nBranch rule: must match \`^[0-9]{3}-\` for /sdd-plan and /sdd-tasks.\n`;
700702
fs.writeFileSync(quickstartPath, qs);
701703
}
702704

0 commit comments

Comments
 (0)