Create Branch
SentryOfficialPublished by Sentry
- Skill
- Workflow
- Software development
- Apache-2.0
- No issues found
AutoGineer summary
Written by AutoGineer from the skill’s own files, not by the author
This skill streamlines the process of creating new Git branches by automatically generating names based on Sentry's established conventions. It analyzes the current state of the repository, including pending changes or existing diffs, to determine an appropriate branch type and descriptive name. The workflow handles base branch detection and collision avoidance automatically, ensuring a consistent and organized development environment without requiring manual input.
What it does
- Analyzes local changes or diffs to suggest a relevant branch description.
- Classifies branches into standard types like feat, fix, ref, or chore.
- Generates kebab-case branch names following specific naming standards.
- Automatically detects the appropriate base branch for the new work.
- Prevents naming collisions by appending numeric suffixes if necessary.
- Executes the branch creation command directly.
When to use it
- When starting new development work on a repository.
- When you need to ensure branch names adhere to team standards.
- When you want to quickly create a branch based on current local changes.
- When you need to perform maintenance or documentation updates.
Advantages
- Ensures consistent branch naming across the project.
- Reduces manual effort by inferring context from local changes.
- Handles complex base branch detection automatically.
- Prevents accidental overwrites or naming conflicts.
Usage examples
- “Create a branch for the new login feature.”
- The agent creates a branch named feat/new-login-feature based on the current repository state.
- “Start a branch for these changes.”
- The agent inspects the current diff, determines the appropriate type, and creates a branch like chore/update-config-files.
Install
Download the skill as a ZIP:
https://autogineer.com/agent-skills/getsentry/create-branch/downloadUnzip it into the cross-client skills folder of your project:
mkdir -p .agents/skills && unzip create-branch.zip -d .agents/skills
Documentation by Sentry
Create Branch
Create a git branch following Sentry naming conventions. Keep this workflow non-interactive unless the user explicitly asks to choose the name manually.
Workflow
Resolve the work description:
If
$ARGUMENTSis present, use itOtherwise inspect:
git diff git diff --cached git status --shortIf there are local changes, derive a short description from the diff
If there are no local changes, use a generic description like
repo-maintenance,tooling-update, orwork-in-progress
Classify the branch type:
| Type | Use when |
|---|---|
feat | New functionality |
fix | Broken behavior now works |
ref | Behavior stays the same, structure changes |
chore | Maintenance of existing tooling/config |
perf | Same behavior, faster |
style | Visual or formatting only |
docs | Documentation only |
test | Tests only |
ci | CI/CD config |
build | Build system |
meta | Repo metadata |
license | License changes |
When unsure: use feat for new things, ref for restructuring, chore for maintenance.
Generate
<type>/<short-description>. Keep<short-description>kebab-case, ASCII-only, and ideally 3 to 6 words.Choose the base without prompting:
git branch --show-current git remote | grep -qx origin && echo origin || git remote | head -1 git symbolic-ref refs/remotes/<remote>/HEAD 2>/dev/null | sed 's|refs/remotes/<remote>/||' | tr -d '[:space:]'If default branch detection fails, fall back to
main, thenmaster, then the current branchIf on a detached HEAD, branch from the current commit
If already on a non-default branch, branch from the current branch
Only switch to the default branch when the user explicitly asks
Avoid collisions by appending
-2,-3, and so on until the name is unused locally and remotely.Create the branch:
git checkout -b <branch-name>Report the final branch name, but do not stop for confirmation.
References
Files
- ATTRIBUTION.mdAdded by AutoGineer850 B
- LICENSELicence file added by AutoGineer10.5 KiB
- SKILL.md2.5 KiB
Requirements and compatibility
Written for: Claude Code
Works with: Claude Code, Claude apps, OpenAI Codex, GitHub Copilot, Cursor, Gemini CLI, Kiro, OpenCode, Goose, Amp, Roo Code, JetBrains Junie, Factory Droid, Devin (ex-Windsurf), Mistral Vibe, OpenHands, Letta
“Works with” means the tool reads the open Agent Skills format; a skill written for one tool may use features others lack.
Needs: Claude Code frontmatter, Needs a command-line tool
Security
No issues found by our static scan· No issues found
A static scan is not a guarantee. Skills are third-party content: review a skill before you let an agent use it.
Attribution and licence
- Published by
- Sentry
- Publisher
- Sentry (Official)
- Source
- getsentry/skills · skills/create-branch · commit e94f222
- Licence
- Apache License 2.0 (redistribution allowed)
- LICENSE (added by AutoGineer from LICENSE)
- ATTRIBUTION.md (written by AutoGineer)
- Synced
AutoGineer is not affiliated with or endorsed by Sentry or Sentry.
Download ZIP
The ZIP holds the skill’s files, its licence files and an ATTRIBUTION.md. Download create-branch.zip