troykelly/claude-skills/clean-commits
Claude Code and agent skill by troykelly/claude-skills
- community
Checking that the SKILL.md file is still in the repository.
Use when committing code - ensures atomic, descriptive commits that leave the codebase in a merge-ready state at every point
Install
npx vskill@latest install troykelly/claude-skills/clean-commitsSKILL.md
Clean Commits
Overview
Every commit is atomic, descriptive, and leaves code in a working state.
Core principle: Anyone should be able to checkout any commit and have working code.
Announce at use: "I'm committing with a descriptive message following clean-commits standards."
Commit Message Format
Structure
Types
| Type | Use For | |
|---|---|---|
feat | New feature | |
fix | Bug fix | |
docs | Documentation only | |
style | Formatting, no code change | |
refactor | Code restructuring | |
test | Adding/fixing tests | |
chore | Maintenance, dependencies |
Examples
Atomic Commits
What Makes a Commit Atomic
| Atomic | Not Atomic | |
|---|---|---|
| One logical change | Multiple unrelated changes | |
| Passes all tests | Breaks tests | |
| Complete feature slice | Half-implemented feature | |
| Can be reverted cleanly | Reverts would break things |
Signs of Non-Atomic Commits
- Commit message uses "and" to describe multiple things
- Diff includes unrelated files
- Some tests fail after commit
- "WIP" in commit message
Splitting Large Changes
If you have multiple changes, commit them separately:
Working State Requirement
Every commit must leave the codebase in a state where:
- [ ] All tests pass
- [ ] Build succeeds
- [ ] Application runs
- [ ] No TypeScript errors
- [ ] No linting errors
Before committing:
If any fail, fix before committing.
Commit Frequency
Commit Often
- After each passing test in TDD cycle
- After each refactoring step
- After completing a logical unit
Don't Wait Too Long
| Too Infrequent | Just Right | |
|---|---|---|
| "Implement entire feature" | "Add user model" | |
| "Fix all bugs" | "Fix session expiry redirect" | |
| "Update everything" | "Update auth dependencies" |
Small is Good
Smaller commits are:
- Easier to review
- Easier to revert
- Easier to bisect
- Easier to understand
The Commit Process
1. Stage Selectively
2. Review Staged Changes
3. Write Descriptive Message
4. Verify After Commit
Commit Message Body
When to include a body:
- Why the change was made (not just what)
- Context that isn't obvious from code
- Trade-offs or alternatives considered
- Breaking changes if any
Body Examples
Issue References
Always reference the issue:
Amending Commits
When to Amend
- Typo in message (if not pushed)
- Forgot to stage a file (if not pushed)
When NOT to Amend
- After pushing to remote
- Changing commits others have based work on
Revert, Don't Delete
If a commit was wrong:
Checklist
Before each commit:
- [ ] Tests pass
- [ ] Build succeeds
- [ ] Change is atomic (one logical unit)
- [ ] Message follows format
- [ ] Message describes why, not just what
- [ ] Issue is referenced
- [ ] No "WIP" or placeholder messages
Integration
This skill is called by:
issue-driven-development- Throughout developmentpr-creation- Before creating PR
This skill enforces:
- Reviewable history
- Revertible changes
- Clear project narrative
Security
- Security scanPassed, 100 of 100Pattern checks on the skill's files.
- Model reviewNot runA model review is scheduled for the next rescan.
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/clean-commits/SKILL.md
Popularity
- Repository stars
- 6
- 7-day trend score
- 10
Stars and forks are for the whole GitHub repository, not this skill alone. Refreshed 24 Mar 2026, 8 months ago.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/troykelly/claude-skills/clean-commits)