Agent skill
git-commit
Use when user says "commit", "commit changes", "git commit", "make a commit", "create a commit", or mentions "/commit". Also use when user asks to stage and commit, write a commit message, or split changes into multiple commits.
Install this agent skill to your Project
npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/other/other/git-commit-dustinliu-dot-claude
SKILL.md
Git Commit with Conventional Commits
Create standardized git commits using Conventional Commits. Analyze the diff and follow the interactive confirmation workflow below.
Workflow
- Analyze: Run
git diff --staged(orgit diffif nothing staged) andgit status --porcelain - Draft: Generate commit message from the diff (type, scope, description)
- Present: Show a single confirmation summary with both the files to stage and the commit message, then wait for user approval
- Execute: After approval, run
git addandgit committogether in one step
Confirmation Summary Format
Present the summary in this format before asking for approval:
Files to stage:
A path/to/new-file
M path/to/changed-file
D path/to/removed-file
R old/path → new/path
Commit message:
<type>(<scope>): <description>
<optional body>
Co-Authored-By: ...
Grouping Changes
If the diff contains multiple unrelated changes, propose splitting into separate commits:
- Stage specific files per logical group:
git add path/to/file1 path/to/file2 - Use
git add -pfor partial file staging - One logical change per commit
- Show a separate confirmation summary for each commit
Interactive Confirmation (Required)
Show the files to stage and the commit message together in a single confirmation. Never stage or commit without explicit user approval.
Co-Authored-By
Include in the commit footer using the current agent name and model name:
Co-Authored-By: Claude Sonnet 4.6 <[email protected]>
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
Didn't find tool you were looking for?