Git Branch Naming Convention
Standard git branch naming conventions for teams. Clear patterns for features, bugfixes, releases, and more. Follow best practices for clean repository.
Branch Type Patterns
feature/ - New feature development
Example:
feature/user-authenticationbugfix/ - Bug fixes
Example:
bugfix/login-errorhotfix/ - Urgent production fixes
Example:
hotfix/security-patchrelease/ - Release preparation
Example:
release/v1.2.0docs/ - Documentation changes
Example:
docs/api-referencerefactor/ - Code refactoring
Example:
refactor/simplify-logictest/ - Test additions/changes
Example:
test/unit-testschore/ - Maintenance tasks
Example:
chore/update-dependencieswip/ - Work in progress
Example:
wip/new-dashboardexperiment/ - Experimental features
Example:
experiment/new-algorithmNaming Best Practices
Use lowercase letters
Separate words with hyphens
Include issue/ticket number
Keep names short and descriptive
Avoid special characters
Use consistent team conventions
Delete merged branches
Use slash for category separation
Examples with Issue Numbers
feature/issue-123-add-login
bugfix/issue-456-fix-crash
hotfix/critical-security-fix
release/v2.1.0
docs/readme-update
Workflow Integration
Create branch: git checkout -b feature/issue-123-new-feature. Work on branch, commit changes. Push: git push -u origin feature/issue-123-new-feature. Create PR/MR. Merge to main. Delete branch: git branch -d feature/issue-123-new-feature. Keep main/master clean, always branch.
Team Conventions
Document conventions in README. Use branch protection on main. Require PR reviews before merge. Auto-delete merged branches. Enforce naming with branch naming rules. CI/CD triggered by branch patterns. Consistency improves collaboration.