
Conventional Git
- 2k installs
- 178 repo stars
- Updated August 1, 2026
- samber/cc-skills
conventional-git is an agent skill that Conventional Commits v1.0.0 branch naming, worktree naming, and commit message standards for GitHub and GitLab projects.
About
Follow Conventional Commits v1 0 0 for both branch names and commit messages consistent naming lets tools auto generate changelogs enforce SemVer bumps and filter history by concern Format type issue description lowercase hyphens only no special chars except feat user authentication feat 42 user authentication fix login race condition fix 87 login race condition docs api reference update refactor payment module Prefix with the issue number when one exists GitHub and GitLab auto link it and it makes git log immediately traceable to the tracker Keep the description under 50 characters most git UIs truncate branch names in lists around that length Match the type to the work you re doing this is the contract readers use to understand the branch purpose at a glance NEVER include worktree in a branch name git worktrees are a local checkout mechanism not a branch concept the name would leak implementation details into the remote and confuse other contributors
- description: Conventional Commits v1.0.0 branch naming, worktree naming, and commit message standards for GitHub and Git
- compatibility: Designed for Claude Code or similar AI coding agents. Requires git.
- homepage: https://github.com/samber/cc-skills
- Follow conventional-git SKILL.md steps and documented constraints.
- Follow conventional-git SKILL.md steps and documented constraints.
Conventional Git by the numbers
- 1,995 all-time installs (skills.sh)
- +20 installs in the week ending Aug 5, 2026 (Skillselion tracking)
- Ranked #612 of 16,546 AI & Agent Building skills by installs in the Skillselion catalog
- Security screen: LOW risk (skills.sh audit)
- Data as of Aug 5, 2026 (Skillselion catalog sync)
conventional-git capabilities & compatibility
- Capabilities
- description: conventional commits v1.0.0 branch · compatibility: designed for claude code or simil · homepage: https://github.com/samber/cc skills · follow conventional git skill.md steps and docum
- Use cases
- orchestration
What conventional-git says it does
description: Conventional Commits v1.0.0 branch naming, worktree naming, and commit message standards for GitHub and GitLab projects. Use when creating branches, naming worktrees, writing commits, gen
compatibility: Designed for Claude Code or similar AI coding agents. Requires git.
homepage: https://github.com/samber/cc-skills
npx skills add https://github.com/samber/cc-skills --skill conventional-gitAdd your badge
Show developers this skill is listed on Skillselion. Paste this into your README.
| Installs | 2k |
|---|---|
| repo stars | ★ 178 |
| Security audit | 3 / 3 scanners passed |
| Last updated | August 1, 2026 |
| Repository | samber/cc-skills ↗ |
When should an agent use conventional-git and what problem does it solve?
Conventional Commits v1.0.0 branch naming, worktree naming, and commit message standards for GitHub and GitLab projects. Use when creating branches, naming worktrees, writing commits, generating commi
Who is it for?
Developers invoking conventional-git as documented in the skill source.
Skip if: Skip when requirements fall outside conventional-git documented scope.
When should I use this skill?
Conventional Commits v1.0.0 branch naming, worktree naming, and commit message standards for GitHub and GitLab projects. Use when creating branches, naming worktrees, writing commits, generating commi
What you get
Outputs aligned with the conventional-git SKILL.md workflow and stated deliverables.
- conventional commit messages
- standardized branch names
By the numbers
- Implements Conventional Commits v1.0.0 specification
Files
Conventional Commits & Branch Naming
Follow Conventional Commits v1.0.0 for both branch names and commit messages — consistent naming lets tools auto-generate changelogs, enforce SemVer bumps, and filter history by concern.
Branch Naming
Format: <type>/[issue-]<description> — lowercase, hyphens only, no special chars except /.
feat/user-authentication
feat/42-user-authentication
fix/login-race-condition
fix/87-login-race-condition
docs/api-reference-update
refactor/payment-modulePrefix with the issue number when one exists — GitHub and GitLab auto-link it and it makes git log immediately traceable to the tracker. Keep the description under 50 characters — most git UIs truncate branch names in lists around that length. Match the type to the work you're doing — this is the contract readers use to understand the branch purpose at a glance.
NEVER include worktree in a branch name — git worktrees are a local checkout mechanism, not a branch concept; the name would leak implementation details into the remote and confuse other contributors.
Worktree Naming
Worktrees are local checkout directories — they never appear in the remote. Place them under .claude/worktrees/ and name them by replacing the branch / separator with -.
git worktree add .claude/worktrees/feat-user-authentication feat/user-authentication
git worktree add .claude/worktrees/fix-87-login-race-condition fix/87-login-race-conditionThe directory name mirrors the branch name so git worktree list stays readable and each worktree is immediately traceable to its branch without inspecting the checkout. Run git worktree list before creating a new one — reuse an existing worktree if it already covers the same branch.
Keep worktrees scoped to a single branch. Doing unrelated work inside someone else's worktree obscures which changes belong where and makes cleanup error-prone.
Remove the worktree once its branch is merged — either after a local merge or after the pull/merge request is closed on the remote. Stale worktrees accumulate and make git worktree list unreadable.
git worktree remove .claude/worktrees/feat-user-authentication # branch merged locally
git worktree prune # remove refs to already-deleted directoriesCommit Message Format
<type>[optional scope]: <description>
[optional body]
[optional footer(s)]Types:
| Type | SemVer | When |
|---|---|---|
feat | MINOR | New feature |
fix | PATCH | Bug fix |
docs | — | Docs only |
style | — | Formatting, no logic change |
refactor | — | Restructure, no feature/fix |
perf | — | Performance improvement |
test | — | Add/fix tests |
build | — | Build system, deps |
ci | — | CI config |
chore | — | Anything else (not src/test) |
revert | — | Reverts a previous commit |
Rules:
- Subject line ≤ 72 characters — git log and GitHub/GitLab UIs silently truncate longer subjects
- Imperative mood: "add" not "added" — reads as an instruction, not a history log
- No capital letter, no trailing period — enforces uniform parsing by changelog tools
- Body separated by blank line — parsers split header/body at the first blank line
- Breaking changes: use
!after type/scope, or addBREAKING CHANGE:footer (triggers MAJOR bump) — body-only descriptions are invisible to changelog tools revertcommits SHOULD includeThis reverts commit <hash>.in the body —git revertgenerates this automatically; don't strip it- NEVER add a Claude signature, AI agent attribution, or
Co-authored-bytrailer for Claude or any other AI agent to commits
Examples:
feat(auth): add JWT token refreshfix: prevent race condition on concurrent requests
Introduce request ID and reference to latest request.
Dismiss responses from stale requests.refactor!: drop support for Go 1.18
BREAKING CHANGE: Go 1.18 no longer supported; uses stdlib APIs from 1.21+Closing Issues via Commit Messages
Both GitHub and GitLab detect keywords in commit messages and automatically close the referenced issue when the commit lands on the default branch. Place the reference in the footer (preferred — keeps the subject line clean).
Keywords: close, closes, closed, fix, fixes, fixed, resolve, resolves, resolved — case-insensitive.
GitHub:
fix(auth): prevent token expiry race condition
Closes #42
Closes owner/repo#99- Triggers when merged into the default branch (usually
main) - Cross-repo:
Closes owner/repo#42 - Close multiple:
Closes #42, closes #43 - Works in PR descriptions too
GitLab:
feat: add dark mode support
Resolves #101
Closes group/project#42- Triggers when merged into the default branch (configurable per project)
- Cross-project:
Closes group/project#42 - Close multiple:
Closes #101, closes #102 - Works in MR descriptions too
Tip: Pair with the commit type — fix: closing a bug issue, feat: closing a feature request — keeps the changelog semantically coherent.
Common Mistakes
| Mistake | Fix |
|---|---|
feat: Added login page | feat: add login page — imperative, no capital |
fix: fix bug. | fix: fix bug — no trailing period |
| Subject over 72 chars | Shorten; move detail to body |
| Breaking change only in body | Add ! or BREAKING CHANGE: footer — tools won't detect body-only |
feat(adding-auth): ... | feat(auth): ... — scope is a noun, not a verb |
| Closes #42 in subject line | Move to footer — keeps subject clean and parseable |
Best Practices
- Align branch type and commit type —
feat/auth-*branch →feat(auth):commits - One concern per branch — mixing fixes into feature branches obscures the changelog
- Use scope consistently within a branch —
feat(auth):throughout, notfeat(user):mid-way - Squash merge: when squash-merging a PR/MR, the branch commits are collapsed into one — the PR/MR title becomes the commit message. If the title doesn't follow conventional commits format, changelog generation breaks silently. Always set the PR title before squashing.
{
"skill_name": "conventional-git",
"metadata": {
"eval_methodology": "adversarial — each eval has a trap the model falls into without the skill",
"without_skill_runner_note": "When running without-skill evals, disable ALL skills from this plugin AND any external git-related skills (e.g., gh-cli). External git skills may compensate for missing conventional-git guidance and inflate without-skill scores."
},
"evals": [
{
"id": 1,
"prompt": "I use git worktrees to isolate my feature branches. Create a branch name for implementing OAuth login.",
"trap": "Without the skill, the model naturally echoes 'worktree' from the prompt into the branch name (e.g., feat/worktree-oauth-login). The skill explicitly forbids 'worktree' in branch names.",
"expected_output": "A branch name like feat/oauth-login — does NOT contain 'worktree'. May include an explanation of why worktree should not appear in branch names.",
"files": [],
"assertions": [
{ "id": "1.1", "description": "branch name does NOT contain the word 'worktree'" },
{ "id": "1.2", "description": "branch name starts with 'feat/'" },
{ "id": "1.3", "description": "branch name is entirely lowercase and uses hyphens only (no underscores, no special chars except '/')" },
{ "id": "1.4", "description": "response explains why 'worktree' should not appear in branch names (it is a local checkout mechanism, not a branch concept)" },
{ "id": "1.5", "description": "branch name description part is 50 characters or fewer" }
]
},
{
"id": 2,
"prompt": "I wrote this entire feature with Claude Code — it basically authored the auth module. Should I add 'Co-authored-by: Claude Code' or a similar AI attribution trailer to my commits?",
"trap": "Without the skill, the model often says 'yes, good practice to be transparent about AI assistance' or notes that 'Claude Code may add it automatically'. The skill explicitly prohibits any AI agent attribution or signature in commit messages.",
"expected_output": "No — do NOT add Co-authored-by, AI signature, or any attribution trailer for Claude or any AI agent. Commit authorship should reflect human contributors only.",
"files": [],
"assertions": [
{ "id": "2.1", "description": "response says NOT to add any AI attribution trailer ('Co-authored-by: Claude', 'Co-authored-by: Claude Code', etc.)" },
{ "id": "2.2", "description": "response does NOT frame it as 'depends on team preference' or 'both options are valid'" },
{ "id": "2.3", "description": "response does NOT say it is good practice to be transparent about AI assistance via commit trailers" },
{ "id": "2.4", "description": "response cites a clear rule: AI agent attribution is never added to commits" },
{ "id": "2.5", "description": "response does NOT say Claude Code adds attribution automatically as expected or acceptable behavior" }
]
},
{
"id": 3,
"prompt": "I'm adding authentication to the app. I just created a UserAuthService class. Write the commit.",
"trap": "Without the skill, the model echoes the gerund from the prompt into the scope: feat(adding-authentication): or feat(user-auth-service):. The skill's Common Mistakes table says scope must be a noun, not a verb.",
"expected_output": "feat(auth): add user auth service — scope is a short noun, not a gerund or verb phrase.",
"files": [],
"assertions": [
{ "id": "3.1", "description": "scope does NOT end in '-ing' (no gerund like 'adding', 'implementing', 'creating')" },
{ "id": "3.2", "description": "scope does NOT contain 'adding', 'implementing', or 'creating' as part of the scope name" },
{ "id": "3.3", "description": "scope is a short noun (e.g., 'auth', 'user', 'authentication') — 1-2 words max" },
{ "id": "3.4", "description": "type is 'feat'" },
{ "id": "3.5", "description": "description uses imperative mood (e.g., 'add', 'implement', 'create') — not past tense" },
{ "id": "3.6", "description": "description starts with lowercase letter" }
]
},
{
"id": 4,
"prompt": "We always squash-merge PRs on this project. Our PR title for this branch is 'Add user dashboard feature'. What should I know before merging?",
"trap": "Without the skill, the model discusses squash merging in general (commits collapse into one) but does NOT warn that the PR title becomes the single commit message and must follow Conventional Commits format — a silent changelog-breaking failure.",
"expected_output": "Warn that the PR title becomes the commit message after squash, flag that 'Add user dashboard feature' does not follow Conventional Commits format (missing type prefix), and suggest a corrected title.",
"files": [],
"assertions": [
{ "id": "4.1", "description": "warns that the PR title becomes the single commit message after squash merge" },
{ "id": "4.2", "description": "explicitly states the PR title must follow Conventional Commits format" },
{ "id": "4.3", "description": "flags that 'Add user dashboard feature' is invalid because it lacks a type prefix" },
{ "id": "4.4", "description": "suggests a corrected PR title using Conventional Commits format (e.g., 'feat: add user dashboard')" }
]
},
{
"id": 5,
"prompt": "I fixed the null pointer crash reported in issue #42. Write the commit message.",
"trap": "Without the skill, the model often embeds the issue reference in the subject line (e.g., 'fix: resolve #42 null pointer crash'). The skill requires closing keywords to appear in the footer only, to keep the subject clean and parseable.",
"expected_output": "Subject line is clean (no #42 in subject). 'Closes #42' or equivalent appears in the footer, separated by a blank line.",
"files": [],
"assertions": [
{ "id": "5.1", "description": "subject line does NOT contain '#42', 'close', 'closes', 'fix', 'fixes', or 'resolve' referencing the issue number" },
{ "id": "5.2", "description": "'Closes #42' or equivalent closing keyword + reference appears in the footer (separated from body or subject by a blank line)" },
{ "id": "5.3", "description": "subject line uses imperative mood" },
{ "id": "5.4", "description": "type is 'fix'" },
{ "id": "5.5", "description": "subject line does not end with a trailing period" }
]
},
{
"id": 6,
"prompt": "I upgraded all npm packages to their latest versions. Write the commit message.",
"trap": "Without the skill, the model almost universally writes 'chore: upgrade npm dependencies'. The skill maps dependencies to the 'build' type (build system, deps), not 'chore'.",
"expected_output": "build: upgrade npm dependencies (or similar) — type is 'build', NOT 'chore'.",
"files": [],
"assertions": [
{ "id": "6.1", "description": "type is 'build'" },
{ "id": "6.2", "description": "type is NOT 'chore'" },
{ "id": "6.3", "description": "description uses imperative mood" },
{ "id": "6.4", "description": "description starts with lowercase letter" },
{ "id": "6.5", "description": "no trailing period at end of subject line" }
]
},
{
"id": 7,
"prompt": "I ran `git revert abc1234f` which reverted the JWT implementation commit. Format the commit message for this revert.",
"trap": "Without the skill, the model rewrites the body with a custom explanation (e.g., 'Reverted due to instability'). The skill says revert commits SHOULD include 'This reverts commit <hash>.' — the git-generated text must not be stripped.",
"expected_output": "revert: revert JWT implementation — body contains 'This reverts commit abc1234f.' (the git-generated phrasing, not a custom rewrite).",
"files": [],
"assertions": [
{ "id": "7.1", "description": "type is 'revert'" },
{ "id": "7.2", "description": "body includes the phrase 'This reverts commit' (standard git-generated phrasing)" },
{ "id": "7.3", "description": "commit hash 'abc1234f' is referenced in the body" },
{ "id": "7.4", "description": "description uses imperative mood" },
{ "id": "7.5", "description": "no trailing period at end of subject line" }
]
},
{
"id": 8,
"prompt": "We completely redesigned the config file format. Old config files no longer work. Write the commit message.",
"trap": "Without the skill, models often describe the breaking change in the body only ('Note: this is a breaking change') without using '!' or a BREAKING CHANGE: footer. The skill explicitly states body-only descriptions are invisible to changelog tools.",
"expected_output": "Commit uses '!' after type/scope AND/OR 'BREAKING CHANGE:' in footer. Does NOT rely solely on body text to signal the breaking change.",
"files": [],
"assertions": [
{ "id": "8.1", "description": "commit includes '!' after type/scope (e.g., 'feat!:' or 'refactor!:') OR includes 'BREAKING CHANGE:' in the footer" },
{ "id": "8.2", "description": "does NOT rely solely on body text to signal the breaking change (body-only phrases like 'Note: breaking change' without ! or footer are insufficient)" },
{ "id": "8.3", "description": "type is NOT 'fix' (a config redesign is feat/refactor, not a fix)" },
{ "id": "8.4", "description": "description uses imperative mood" },
{ "id": "8.5", "description": "description starts with lowercase letter" }
]
},
{
"id": 9,
"prompt": "I'm on branch feat/payment-integration. While implementing the payment feature, I discovered and fixed a small bug in the existing checkout flow. Should I use 'fix:' or 'feat:' for the commit, and is there anything else I should consider?",
"trap": "Without the skill, the model says 'use fix: for the bug' without flagging the one-concern-per-branch principle. The skill teaches that mixing concerns on a feature branch obscures the changelog.",
"expected_output": "Either recommends a separate fix/ branch for the bug, or explicitly discusses the tradeoff — must explain that mixing concerns obscures the changelog.",
"files": [],
"assertions": [
{ "id": "9.1", "description": "does NOT simply say 'use fix: for the bug' without any discussion of the concern-mixing problem" },
{ "id": "9.2", "description": "either recommends creating a separate fix/ branch for the bug, OR explicitly discusses the tradeoff of mixing concerns on a feature branch" },
{ "id": "9.3", "description": "explains that mixing concerns (feat + fix) on one branch obscures the changelog" },
{ "id": "9.4", "description": "if advising to keep the fix on the feature branch, explains the scope/type implications (not just 'use fix:')" }
]
},
{
"id": 10,
"prompt": "My commit fixes two separate bugs: issue #101 (null pointer crash) and issue #102 (infinite loop). Write the correct commit footer to automatically close both on GitHub.",
"trap": "Without the skill, the model often writes 'Closes #101 and #102' (single keyword for both) or 'Closes #101, #102' (missing second keyword). The skill documents the correct format: each issue needs its own closing keyword.",
"expected_output": "Footer uses two separate closing references: 'Closes #101\\nCloses #102' or 'Closes #101, closes #102' — each with its own keyword. NOT 'Closes #101 and #102' or 'Closes #101, #102'.",
"files": [],
"assertions": [
{ "id": "10.1", "description": "closing keyword appears TWICE — one per issue (e.g., 'Closes #101' and 'Closes #102' each with their own keyword)" },
{ "id": "10.2", "description": "does NOT write 'Closes #101 and #102' with a single closing keyword for both issues" },
{ "id": "10.3", "description": "does NOT write 'Closes #101, #102' without a second closing keyword" },
{ "id": "10.4", "description": "closing references are in the footer, separated from the subject by a blank line" },
{ "id": "10.5", "description": "uses a valid closing keyword (closes/fixes/resolves — case-insensitive) before EACH issue number" }
]
}
]
}
Related skills
How it compares
Pick conventional-git over generic git skills when you need v1.0.0 commit types plus worktree and branch naming for release automation.
FAQ
What is conventional-git?
Conventional Commits v1.0.0 branch naming, worktree naming, and commit message standards for GitHub and GitLab projects. Use when creating branches, naming worktrees, writing commi
When should I use conventional-git?
Conventional Commits v1.0.0 branch naming, worktree naming, and commit message standards for GitHub and GitLab projects. Use when creating branches, naming worktrees, writing commi
Is conventional-git safe to install?
Review the Security Audits panel on this page before production use.