spec-kit icon indicating copy to clipboard operation
spec-kit copied to clipboard

Different commands produce/expect different branch name syntax

Open diarized opened this issue 1 year ago • 4 comments

> I can see some mistakes in the tasks. Several and important. Probably the plan needs 
further clarification. Please delete the task document and let me clarify the plan using 
'/speckit.clarify' command. 

● I'll delete the tasks document and run the clarify command for you.

● Bash(rm specs/1-url-migration/tasks.md)
  ⎿  (No content)
  ⎿  Error: Unknown slash command: speckit.clarify

● Bash(ls -la .claude/commands/)
  ⎿  total 164                                     
     drwxrwxr-x 2 artur artur  4096 Nov 11 10:07 .
     drwxr-x--- 4 artur artur  4096 Nov 10 21:23 ..
     … +25 lines (ctrl+o to expand)

● Read(.claude/commands/speckit.clarify.md)
  ⎿  Read 178 lines

● I'll run the clarify workflow for you. Let me start by checking the prerequisites and
  loading the current spec.

● Bash(.specify/scripts/bash/check-prerequisites.sh --json --paths-only)
  ⎿  Error: Exit code 1
     ERROR: Not on a feature branch. Current branch: 1-url-migration
     Feature branches should be named like: 001-feature-name

● The script has a strict branch naming requirement, but I can proceed with the
  clarification workflow using the known paths. Let me load the current spec file.

● Read(specs/1-url-migration/spec.md)
  ⎿  Read 426 lines

● Perfect! I've loaded the current specification (version 1.1.0). I'm ready to receive
  your clarifications.

diarized avatar Nov 11 '25 10:11 diarized

Sometimes hard to reproduce:

> /speckit.specify is running… I'd like to fix a bug in templates causing the command 'plan' 
(plan.md template) to create a git branch named X-name-of-the-feature, while the following 
steps of the workflow (for example 'tasks' - task.md in templates) expect the branch name to 
be called XXX-name-of-the-feature (where X is a digit). 

● I'll help you create a specification for fixing the branch naming inconsistency bug. Let
   me start by generating a short name and checking for existing branches.

● Bash(git fetch --all --prune)
  ⎿  (No content)

● Now let me check for existing branches and specs directories with the short name
  "fix-branch-naming":

● Bash(git ls-remote --heads origin | grep -E 'refs/heads/[0-9]+-fix-branch-naming$' | sed
      's/.*refs\/heads\///' | grep -oE '^[0-9]+' | sort -n | tail -1)
  ⎿  (No content)

● Bash(git branch | grep -E '^[* ]*[0-9]+-fix-branch-naming$' | sed 's/^[* ]*//' | grep -oE
      '^[0-9]+' | sort -n | tail -1)
  ⎿  (No content)

● Bash(ls -d .specify/specs/[0-9]*-fix-branch-naming 2>/dev/null | grep -oE '[0-9]+' | sort -n
       | tail -1)
  ⎿  (No content)

● No existing branches found with this name, so I'll start with number 1. Now let me run
  the create-new-feature script:

● Bash(.specify/scripts/bash/create-new-feature.sh --json "I'd like to fix a bug in templates
      causing the command 'plan' (plan.md template) to create a git branch name…)
  ⎿ {                                                                                    
      "BRANCH_NAME": "001-fix-branch-naming",
      "SPEC_FILE": "/home/diarized/Scripts/Shell/spec-kit/specs/001-fix-branch-naming/spec.m
    … +4 lines (ctrl+o to expand)


● Perfect! The branch 001-fix-branch-naming has been created. Now let me load the spec
  template and write the specification:

diarized avatar Nov 11 '25 18:11 diarized

Happens only if /speckit.clarify is used after /speckit.plan

diarized avatar Nov 16 '25 11:11 diarized

This issue has been automatically marked as stale because it has not had any activity for 150 days. It will be closed in 30 days if no further activity occurs.

github-actions[bot] avatar Apr 16 '26 00:04 github-actions[bot]

This issue has been automatically closed due to inactivity (180 days total). If you believe this issue is still relevant, please reopen it or create a new issue.

github-actions[bot] avatar May 16 '26 01:05 github-actions[bot]