commit-work
Installation
SKILL.md
Commit work
Workflow
- Read repository instructions and inspect the current branch,
git status, unstaged diff, and staged diff. - Identify the user-authorized scope. Preserve unrelated, pre-existing, ignored, and untracked work.
- Choose the fewest logical commits that keep unrelated concerns separate. Keep inseparable implementation and focused tests together.
- Infer the message convention from repository instructions and recent commits. Use Conventional Commits only when required by the repository or requested by the user.
- Stage explicit paths. Use patch staging for mixed files. Avoid
git add .,git add -A, andgit commit -amunless the whole worktree is confirmed in scope. - Review
git diff --cached,git diff --cached --stat, andgit diff --cached --check. Check for unrelated churn, debug output, credentials, generated files, and accidental deletions. - Run the smallest meaningful verification for the staged behavior and record the real result.
- Compose the message from the staged outcome:
- make the subject specific and imperative;
- explain why or user-visible impact in the body only when it is not obvious;
- add issue, co-author, sign-off, or breaking-change trailers only when true and repository-appropriate.
- Commit without bypassing hooks. Verify the resulting subject and scope with
git show --stat --oneline --decorate HEAD. - Repeat for the next boundary, then verify
git status -sband the resulting commit list.