agentleFS
haruharu/redmine_ai_helper/.claude/skills/speckit-git-feature/SKILL.md

speckit-git-feature

Skill107 starsChanged 9 months agoMITView on GitHub

Create a feature branch with sequential or timestamp numbering

36 other projects use a version of this, 36 of them edited.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

12 rules. 4 are common, 0 are distinctive, and 8 are very specific to this project.

  • 4

    Common

    Most of the 36 edited versions we read keep these.

  • 0

    Distinctive

    This author's own choices. Worth a look.

  • 8

    Very specific

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

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

    Create and switch to a new git feature branch for the given specification.

    line 16
  2. Very specific:

    If the user explicitly provided GIT_BRANCH_NAME (e.g., via environment variable, argument, or in their request), pass it through to the …

    line 28
  3. Very specific:

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

    line 35
  4. Common:

    If Git is not available, warn the user and skip branch creation

    line 36
  5. Very specific:

    Check .specify/extensions/git/git-config.yml for branch_numbering value

    line 42
  6. Very specific:

    Check .specify/init-options.json for branch_numbering value (backward compatibility)

    line 43
  7. Very specific:

    Default to sequential if neither exists

    line 44
  8. Common:

    Use action-noun format when possible (e.g., "add-user-auth", "fix-payment-bug")

    line 50
  9. Common:

    Run the appropriate script based on your platform:

    line 53
  10. Very specific:

    Do NOT pass --number — the script determines the correct next number automatically

    line 61
  11. Very specific:

    Always include the JSON flag (--json for Bash, -Json for PowerShell) so the output can be parsed reliably

    line 62
  12. Common:

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

    line 68

“Common” is measured: kept by at least 6 in 10 of the 36 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

Git Feature Skill

Create Feature Branch

Create 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.

User Input

$ARGUMENTS

You MUST consider the user input before proceeding (if not empty).

Environment Variable Override

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:

  • The script uses the exact value as the branch name, bypassing all prefix/suffix generation
  • --short-name, --number, and --timestamp flags are ignored
  • FEATURE_NUM is extracted from the name if it starts with a numeric prefix, otherwise set to the full branch name

Prerequisites

  • Verify Git is available by running git rev-parse --is-inside-work-tree 2>/dev/null
  • If Git is not available, warn the user and skip branch creation

Branch Numbering Mode

Determine the branch numbering strategy by checking configuration in this order:

  1. Check .specify/extensions/git/git-config.yml for branch_numbering value
  2. Check .specify/init-options.json for branch_numbering value (backward compatibility)
  3. Default to sequential if neither exists

Execution

Generate a concise short name (2-4 words) for the branch:

  • Analyze the feature description and extract the most meaningful keywords
  • Use action-noun format when possible (e.g., "add-user-auth", "fix-payment-bug")
  • Preserve technical terms and acronyms (OAuth2, API, JWT, etc.)

Run the appropriate script based on your platform:

  • Bash: .specify/extensions/git/scripts/bash/create-new-feature.sh --json --short-name "<short-name>" "<feature description>"
  • Bash (timestamp): .specify/extensions/git/scripts/bash/create-new-feature.sh --json --timestamp --short-name "<short-name>" "<feature description>"
  • PowerShell: .specify/extensions/git/scripts/powershell/create-new-feature.ps1 -Json -ShortName "<short-name>" "<feature description>"
  • PowerShell (timestamp): .specify/extensions/git/scripts/powershell/create-new-feature.ps1 -Json -Timestamp -ShortName "<short-name>" "<feature description>"

IMPORTANT:

  • Do NOT pass --number — the script determines the correct next number automatically
  • Always include the JSON flag (--json for Bash, -Json for PowerShell) so the output can be parsed reliably
  • You must only ever run this script once per feature
  • The JSON output will contain BRANCH_NAME and FEATURE_NUM

Graceful Degradation

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

  • Branch creation is skipped with a warning: [specify] Warning: Git repository not detected; skipped branch creation
  • The script still outputs BRANCH_NAME and FEATURE_NUM so the caller can reference them

Output

The 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 used

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.