code-commit skill
Generate and validate git commit messages following the conventionalcommits.org specification.
- GitHub stars
- 51
- Files
- 1
- Last commit
- Nov 7, 2026
- License
- MIT
- Allowed tools
- —
What does the code-commit skill do?
code-commit generates and validate git commit messages following the conventionalcommits.org specification.
Summary generated from the skill's SKILL.md.
About the code-commit skill
Writing standardized git commit messages that follow the conventionalcommits.org specification is what this skill enables for developers. It automates the process of inspecting a worktree, analyzing changes, and drafting messages that include a specific type, scope, and imperative title. An agent should load this tool whenever a user mentions committing code, asks to create a commit, or needs to review the format of an existing message.
To ensure accuracy, the skill uses commands like git status, git diff, and git log to understand the context of changes and match established repository patterns. It identifies appropriate types such as feat, fix, or refactor and handles breaking changes using the required syntax. The process includes a safety layer where the agent proposes specific files and messages for approval before executing git add or git commit. It also respects repository commit hooks and can delegate pull request creation to other specialized tools.
What an agent can do with it
- 1Generate a new commitAn agent can inspect the current worktree and propose a formatted commit message for the user to approve.
- 2Validate message syntaxDevelopers can check if a specific commit message adheres to the conventional commits standard.
- 3Identify breaking changesThe skill can format messages to clearly indicate breaking changes using specific footers and symbols.
- 4Review staged changesThe tool analyzes diffs to ensure the commit message accurately describes the actual code modifications.
Written from the skill's SKILL.md. Every use case is checked against a quote from it.
How to install the code-commit skill
Each command copies the skill folder into the client's skills directory. Restart the client or start a new session to load it.Install the code-commit skill in Plugin
/plugin marketplace add martinffx/atelier /plugin install atelier@atelier
Install the code-commit skill in Claude Code
~/.claude/skills/code-commit/SKILL.md
$ npx degit martinffx/atelier/skills/code-commit ~/.claude/skills/code-commitInstall the code-commit skill in Claude Code (project)
.claude/skills/code-commit/SKILL.md
$ npx degit martinffx/atelier/skills/code-commit .claude/skills/code-commitInstall the code-commit skill in Codex
~/.agents/skills/code-commit/SKILL.md
$ npx degit martinffx/atelier/skills/code-commit ~/.agents/skills/code-commitInstall the code-commit skill in Gemini CLI
~/.gemini/skills/code-commit/SKILL.md
$ npx degit martinffx/atelier/skills/code-commit ~/.gemini/skills/code-commitInstall the code-commit skill in Claude.ai
npx degit martinffx/atelier/skills/code-commit code-commit && zip -r code-commit.zip code-commit # claude.ai → Customize → Skills → + → Create skill → Upload a skill → code-commit.zip
SKILL.md
View on GitHubConventional Commit Skill
Create coherent, reviewable commits that follow the Conventional Commits specification. Message syntax matters, but the selected changes must tell one clear story too.
Message Format
Every generated commit has a title and body:
<type>(<scope>): <imperative title>
<1-5 lines describing the change and, when useful, its reason or effect>
Use a lowercase scope that identifies the affected component. The title is concise, imperative, lowercase, and has no trailing period. The body is concrete: explain the behavior, motivation, or important implementation decision rather than restating the title.
| Type | Use for |
|---|---|
feat |
New user-facing capability |
fix |
Corrected behavior |
docs |
Documentation only |
style |
Formatting only |
refactor |
Restructuring without behavior change |
test |
Tests only |
chore |
Maintenance or tooling |
perf |
Performance improvement |
ci |
Continuous integration configuration |
build |
Build system or dependencies |
revert |
Reverting a prior commit |
Breaking changes may use ! after the type or scope, a BREAKING CHANGE: footer, or both.
Include issue footers such as Closes #123 only when the issue is known.
Create a Commit
When the user asks to commit, first inspect the complete worktree:
- Run
git status --short. - Read both
git diff --cachedandgit diffso pre-staged work is not mistaken for the entire change. - List untracked files with
git ls-files --others --exclude-standardand inspect relevant ones. - Read recent subjects with
git log --oneline -10to match established scopes and wording. - Flag likely secrets, credentials, local configuration, or generated output. Do not stage them without explicit direction.
Decide Whether to Split
Default to one commit containing all intended, related changes. Look for an obvious file-level split only when changes are independent and each group can stand alone.
Keep these together:
- Implementation and its tests.
- Documentation that describes the same change.
- Dependency manifests and their lockfiles.
Do not invent a split for adjacent work, use hunk-level staging, or force the user to reorganize a coherent change. If an obvious split exists, propose each commit with its files and full message, then ask once for approval. If not, propose one commit.
Approve, Stage, Commit
Before making any write, show:
- The files in each proposed commit.
- The full title and 1-5 line body for each commit.
- Any excluded files and why they are excluded.
Ask for approval unless the user explicitly authorizes committing immediately. After
approval, stage only the files for the approved commit with git add -- <paths> and
inspect git diff --cached --name-status and git diff --cached again. If the staged snapshot
contains any unapproved file, stop and ask how to handle it. Then commit with the proposed title
and body. Do not amend, rebase, push, or include unapproved files.
Repository commit hooks are the final message validation when configured. Never bypass a failing hook. Report the commit hash on success; report the error and leave changes intact on failure.
Validate a Commit Message
When the user asks to validate a message, check:
- It follows
type(scope): imperative title. - The type is listed above and the scope is lowercase.
- The title is lowercase, imperative, concise, and has no trailing period.
- A body follows after a blank line and contains 1-5 meaningful lines.
- Breaking changes use both
!and aBREAKING CHANGE:footer.
Return specific corrections and a revised message. When the repository configures commitlint, use it as the authoritative validation rule.
Delegated: Pull Request Creation
If the user wants to create a PR after committing, invoke the
code-pull-request skill. It detects the platform
(GitHub/GitLab), finds a template, generates the body, and opens the PR via gh
or glab.
Input Methods
| Input | Action |
|---|---|
| User says "commit" or "git commit" | Inspect the worktree, propose coherent commit(s), then commit after approval |
| User says "validate commit" | Check the commit message format |
| User pastes commit message | Validate the provided message |
Error Handling
- If there are no changes: report that there is nothing to commit.
- If Git is not initialized: report it; do not initialize a repository unless asked.
- If a commit fails: show the error, preserve the worktree, and do not bypass hooks.
Examples
Input: "I fixed the login bug" Output:
fix(auth): resolve login timeout issue
Correct token expiry calculation so active users are not logged out after five minutes.
Input: "I added a new API endpoint for users" Output:
feat(api): add user profile endpoint
Expose name, email, and avatar URL from `GET /users/:id`.
Closes #89
Input: "I changed the auth API, this breaks old clients" Output:
feat(auth)!: change token validation endpoint
Require a Bearer token on `/auth/verify` instead of a query parameter.
BREAKING CHANGE: Clients must update to send
Authorization header with Bearer token.
Files in this skill
1code-commit skill questions
How do I install the code-commit skill in Claude Code?
Run npx degit martinffx/atelier/skills/code-commit ~/.claude/skills/code-commit. Claude Code loads skills from ~/.claude/skills (all projects) or .claude/skills (one project) and uses a skill when its description matches the task.
Which clients can use the code-commit skill?
Any client that reads the Agent Skills format: Claude Code, Codex, Gemini CLI and claude.ai (upload as a ZIP). Scripts in the skill run only where the client allows code execution.
What is the required format for a conventional commit message?
The format consists of a type and optional scope, followed by an imperative title, and an optional body of 1-5 lines.
How should breaking changes be indicated in a commit message?
Breaking changes can be indicated by using an exclamation mark after the type or scope, including a 'BREAKING CHANGE:' footer, or both.
What steps does the agent take before committing code?
The agent inspects the worktree using git status, reads diffs, lists untracked files, checks recent logs, and flags potential secrets.