agentleFS
automateyournetworkautomateyournetwork/netclaw/.agents/skills/speckit-git-validate/SKILL.md

speckit-git-validate

Skill718 starsChanged 34 days agoApache-2.0View on GitHub

Validate current branch follows feature branch naming conventions

35 other projects use a version of this, 14 of them edited.

Adopted by

Most recently taken up by

Used with

Projects with it also use speckit-converge and commit.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • Microsoft AzureSkill

    speckit-converge

    Assess the current codebase against the feature's spec, plan, and tasks, then append any remaining unbuilt work as new tasks to tasks.md so implement can complete it.

    Also in 5 projects that use this

  • SentrySkill

    commit

    Create commit messages following Sentry conventions. Use when committing code changes, writing commit messages, or formatting git history. Follows conventional commits with Sentry-specific issue references.

    Also in 3 projects that use this

The file

We split this skill into the rules it gives an agent

11 rules. 6 are common, 0 are distinctive, and 5 are very specific to this project.

  • 6

    Common

    Most of the 14 edited versions we read keep these.

  • 0

    Distinctive

    This author's own choices. Worth a look.

  • 5

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Check if Git is available by running git rev-parse --is-inside-work-tree 2>/dev/null

    line 16
  2. Common:

    If Git is not available, output a warning and skip validation:

    line 17
  3. Common:

    If on a feature branch (matches either pattern):

    line 37
  4. Very specific:

    Check if the corresponding spec directory exists under specs/:

    line 39
  5. Very specific:

    If spec directory exists: ✓ Spec directory found: <path>

    line 42
  6. Very specific:

    If spec directory missing: ⚠ No spec directory found for prefix <prefix>

    line 43
  7. Common:

    If NOT on a feature branch:

    line 45
  8. Common:

    If Git is not installed or the directory is not a Git repository:

    line 51
  9. Very specific:

    Check the SPECIFY_FEATURE environment variable as a fallback

    line 52
  10. Common:

    If set, validate that value against the naming patterns

    line 53
  11. Common:

    If not set, skip validation with a warning

    line 54

“Common” is measured: kept by at least 6 in 10 of the 14 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Validate Feature Branch

Validate that the current Git branch follows the expected feature branch naming conventions.

Prerequisites

  • Check if Git is available by running git rev-parse --is-inside-work-tree 2>/dev/null
  • If Git is not available, output a warning and skip validation:
    [specify] Warning: Git repository not detected; skipped branch validation

Validation Rules

Get the current branch name:

git rev-parse --abbrev-ref HEAD

The branch name must match one of these patterns:

  1. Sequential: ^[0-9]{3,}- (e.g., 001-feature-name, 042-fix-bug, 1000-big-feature)
  2. Timestamp: ^[0-9]{8}-[0-9]{6}- (e.g., 20260319-143022-feature-name)

Execution

If on a feature branch (matches either pattern):

  • Output: ✓ On feature branch: <branch-name>
  • Check if the corresponding spec directory exists under specs/:
    • For sequential branches, look for specs/<prefix>-* where prefix matches the numeric portion
    • For timestamp branches, look for specs/<prefix>-* where prefix matches the YYYYMMDD-HHMMSS portion
  • If spec directory exists: ✓ Spec directory found: <path>
  • If spec directory missing: ⚠ No spec directory found for prefix <prefix>

If NOT on a feature branch:

  • Output: ✗ Not on a feature branch. Current branch: <branch-name>
  • Output: Feature branches should be named like: 001-feature-name or 20260319-143022-feature-name

Graceful Degradation

If Git is not installed or the directory is not a Git repository:

  • Check the SPECIFY_FEATURE environment variable as a fallback
  • If set, validate that value against the naming patterns
  • If not set, skip validation with a warning

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.