Create a feature branch with sequential or timestamp numbering
49
55%
Does it follow best practices?
Impact
—
No eval scenarios have been run
Passed
No known issues
Optimize this skill with Tessl
npx tessl skill review --optimize ./.claude/skills/speckit-git-feature/SKILL.mdCreate and switch to a new git feature branch for the given specification. This command handles branch creation only — the spec directory and files are created by the core /speckit.specify workflow.
$ARGUMENTSYou MUST consider the user input before proceeding (if not empty).
If the user explicitly provided GIT_BRANCH_NAME (e.g., via environment variable, argument, or in their request), pass it through to the script by setting the GIT_BRANCH_NAME environment variable before invoking the script. When GIT_BRANCH_NAME is set:
--short-name, --number, and --timestamp flags are ignoredFEATURE_NUM is extracted from the name if it starts with a numeric prefix, otherwise set to the full branch namegit rev-parse --is-inside-work-tree 2>/dev/nullDetermine the branch numbering strategy by checking configuration in this order:
.specify/extensions/git/git-config.yml for branch_numbering value.specify/init-options.json for branch_numbering value (backward compatibility)sequential if neither existsGenerate a concise short name (2-4 words) for the branch:
Run the appropriate script based on your platform:
.specify/extensions/git/scripts/bash/create-new-feature.sh --json --short-name "<short-name>" "<feature description>".specify/extensions/git/scripts/bash/create-new-feature.sh --json --timestamp --short-name "<short-name>" "<feature description>".specify/extensions/git/scripts/powershell/create-new-feature.ps1 -Json -ShortName "<short-name>" "<feature description>".specify/extensions/git/scripts/powershell/create-new-feature.ps1 -Json -Timestamp -ShortName "<short-name>" "<feature description>"IMPORTANT:
--number — the script determines the correct next number automatically--json for Bash, -Json for PowerShell) so the output can be parsed reliablyBRANCH_NAME and FEATURE_NUMIf Git is not installed or the current directory is not a Git repository:
[specify] Warning: Git repository not detected; skipped branch creationBRANCH_NAME and FEATURE_NUM so the caller can reference themThe script outputs JSON with:
BRANCH_NAME: The branch name (e.g., 003-user-auth or 20260319-143022-user-auth)FEATURE_NUM: The numeric or timestamp prefix used3ce3191
If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.