This skill should be used when the user asks to "commit", "create a commit", "write a commit message", "commit my changes", "commit the changes", or needs help crafting a well-structured git commit message following best practices.
View on GitHubeabay/claude-code-plugins
dev-essentials
plugins/dev-essentials/skills/commit/SKILL.md
January 22, 2026
Select agents to install to:
npx add-skill https://github.com/eabay/claude-code-plugins/blob/main/plugins/dev-essentials/skills/commit/SKILL.md -a claude-code --skill commitInstallation paths:
.claude/skills/commit/# Commit Skill
Create well-crafted git commit messages following established best practices.
## Purpose
Generate commit messages that effectively communicate context about changes to fellow developers and future maintainers. A diff shows _what_ changed; the commit message explains _why_.
## Workflow
### 1. Analyze Changes
Run these commands to understand the current state:
```bash
git status
git diff --staged
git diff
git log --oneline -5
```
Review:
- What files are modified, added, or deleted
- The nature of the changes (bug fix, feature, refactor, docs, etc.)
- Recent commit message style in the repository
### 2. Stage Appropriate Files
**Critical**: Only commit files modified during the current session. Never use `git add -A` or `git add .` unless explicitly instructed.
```bash
git add <specific-file-paths>
```
### 3. Craft the Commit Message
Apply the seven rules from `references/git-commit-guide.md`:
1. **Separate subject from body** with a blank line
2. **Limit subject to 50 characters** (72 hard limit)
3. **Capitalize the subject line**
4. **No period** at end of subject
5. **Use imperative mood** in subject ("Add feature" not "Added feature")
6. **Wrap body at 72 characters**
7. **Explain what and why**, not how
#### Subject Line Test
A proper subject completes this sentence:
> If applied, this commit will _[your subject line]_
Examples:
- "Add user authentication middleware" ✓
- "Fix race condition in connection pool" ✓
- "Added new feature" ✗ (not imperative)
- "Fixing bug" ✗ (not imperative)
### 4. Commit Format
For simple changes (no body needed):
```bash
git commit -m "Fix typo in README installation section"
```
For changes requiring explanation:
```bash
git commit -m "$(cat <<'EOF'
Refactor database connection handling
The previous implementation created a new connection for each query,
causing performance issues under load. This change introduces connection
pooling with a configurable pool size.
- Add ConnectionPool class with