speckit-git-validate

Validates that the current Git branch follows spec-kit feature branch naming conventions.

Updated Jan 28, 2026
One-click install
npx skills add https://github.com/alkampfergit/cisharpai --skill speckit-git-validate-alkampfergit
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: speckit-git-validate
Source: https://github.com/alkampfergit/cisharpai/tree/main/.claude/skills/speckit-git-validate
Command: npx skills add https://github.com/alkampfergit/cisharpai --skill speckit-git-validate-alkampfergit

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Teams using spec-kit workflows need feature branches to follow strict naming conventions so specs, branches, and directories stay aligned. This Skill checks the current Git branch against the expected patterns and reports mismatches before work proceeds on the wrong branch. ## Core Features & Use Cases - Branch Pattern Validation: Checks the current branch against sequential patterns like 001-feature-name and timestamp patterns like 20260319-143022-feature-name. - Spec Directory Detection: Verifies that a matching spec directory exists under specs/ for the branch prefix. - Graceful Degradation: Falls back to the SPECIFY_FEATURE environment variable or skips with a warning when Git is unavailable. - Use Case: Before running a spec-kit planning or implementation command, validate that you are on branch 042-fix-bug and that specs/042-* exists, catching misnamed branches early. ## Quick Start Ask the assistant to validate that the current Git branch follows the spec-kit feature branch naming conventions.

Frequently Asked Questions about speckit-git-validate

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I validate a Git feature branch name in a spec-kit project?▼

Run the validation to compare the current branch from git rev-parse against two patterns: sequential names like 001-feature-name and timestamp names like 20260319-143022-feature-name. It reports whether the branch matches and whether a corresponding specs directory exists.

What branch naming conventions does spec-kit use?▼

Spec-kit feature branches use either a sequential numeric prefix of three or more digits followed by a hyphen, such as 042-fix-bug, or a timestamp prefix in YYYYMMDD-HHMMSS format, such as 20260319-143022-feature-name.

What happens if Git is not installed or the directory is not a repository?▼

The validation degrades gracefully by checking the SPECIFY_FEATURE environment variable as a fallback and validating that value against the naming patterns. If neither is available, it skips validation and prints a warning instead of failing.

Does branch validation check for the matching spec directory?▼

Yes. When the branch matches a valid pattern, it looks under specs/ for a directory whose prefix matches the numeric or timestamp portion of the branch name and reports whether that directory was found.

Why does branch validation fail on my main or develop branch?▼

Branches like main or develop do not match the feature branch patterns, so validation reports that you are not on a feature branch. Switch to a properly named branch such as 001-feature-name before running spec-kit feature workflows.