create-feature-branch
Create a new feature branch following Git Flow strategy. Use when starting new feature development, creating a branch for an issue, or when user says "create branch", "new feature", "start working on issue".
When & Why to Use This Skill
This Claude skill automates the Git Flow branching process to ensure consistent repository structure and team workflow compliance. By handling the synchronization of the develop branch and enforcing standardized naming conventions (e.g., feat/, fix/, refactor/), it streamlines the transition from issue tracking to active development, reducing manual errors and improving project traceability.
Use Cases
- New Feature Initiation: Automatically create a standardized 'feat/' branch from the latest develop branch when starting a new task, ensuring the local environment is clean and up-to-date.
- Bug Fix Management: Quickly generate 'fix/' branches linked to specific issue numbers to maintain a clear history and facilitate easier code reviews and merges.
- Workflow Standardization: Enforce Git Flow best practices across a development team by automating the checklist for branch creation, including naming rules and base-branch verification.
- Codebase Maintenance: Streamline refactoring and dependency updates by creating dedicated 'refactor/' or 'update/' branches that follow the project's structural requirements.
| name | create-feature-branch |
|---|---|
| description | Create a new feature branch following Git Flow strategy. Use when starting new feature development, creating a branch for an issue, or when user says "create branch", "new feature", "start working on issue". |
| allowed-tools | Bash, Read |
Create Feature Branch
This skill creates feature branches following the project's Git Flow strategy.
Branch Naming Convention
| Prefix | Purpose | Example |
|---|---|---|
feat/ |
New feature | feat/issue-88-return-mode |
fix/ |
Bug fix | fix/stdout-encoding |
refactor/ |
Refactoring | refactor/output-processor |
update/ |
Dependency updates | update/jsr-packages |
remove/ |
Feature removal | remove/deprecated-api |
Workflow
1. Ensure clean working directory
git status
If there are uncommitted changes, ask user how to handle them.
2. Update develop branch
git checkout develop
git pull origin develop
3. Create feature branch
Format: {prefix}/issue-{number}-{short-description}
git checkout -b feat/issue-{NUMBER}-{DESCRIPTION}
4. Confirm creation
git branch --show-current
Checklist
- Working directory is clean
- develop branch is up to date
- Branch name follows convention
- Branch is created from develop
Example
For Issue #88 (add return mode):
git checkout develop
git pull origin develop
git checkout -b feat/issue-88-return-mode
Notes
- Always branch from
develop, notmain - Include issue number in branch name for traceability
- Use lowercase with hyphens for descriptions