| name | lazy-commit |
| description | Create well-structured atomic git commits from uncommitted changes using conventional commit messages. Use when asked to commit, stage, create commits, clean up uncommitted work, or prepare changes for push. Handles grouping related changes into logical commits and writing proper commit messages. |
Lazy Commit
Create atomic commits for each logical change with conventional commit messages.
Commit Process
-
Assess state
git status --porcelain
git diff --stat
git diff --cached --stat
-
Analyze changes
git diff
git diff --cached
- Review content of each change
- Identify related changes that belong together
-
Group into logical commits
- Each commit = ONE logical change
- Related files committed together
- Order: dependencies first, then dependents
-
Create commits
git add <specific-files>
git commit -m "<type>: <brief description>"
Conventional Commit Types
| Type | Use |
|---|
feat: | New feature |
fix: | Bug fix |
refactor: | Code restructuring (no behavior change) |
docs: | Documentation |
style: | Formatting (no code change) |
test: | Tests |
chore: | Maintenance, deps, config |
Message Guidelines
- Under 72 characters
- Imperative mood ("add" not "added")
- Specific but concise
- No period at end
Examples:
feat: add user authentication endpoint
fix: resolve null pointer in config parser
refactor: extract validation logic to separate module
Push (Optional)
Only push if explicitly requested:
git push origin <current-branch>