commit
Use when the user asks to commit, create a git commit, checkpoint changes, save work to git, or write a commit message.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Use when the user asks to commit, create a git commit, checkpoint changes, save work to git, or write a commit message.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
Use when auditing comments, docstrings, or embedded documentation prose in a scope — to strip bloat and rewrite cluttered-but-justified entries. Triggers on "audit comments", "clean up docstrings", "strip stale comments", "comment cleanup".
Use when the goal is to reduce code size, remove unnecessary complexity, or simplify a module without removing user-facing behavior.
Use when auditing and fixing end-to-end contracts and compatibility in a scope — HTTP/RPC APIs, events/messages, schemas, files, CLIs, libraries, configuration, database consumers, and external integrations. Triggers on "audit contracts", "API compatibility review", "schema compatibility audit", "check producer/consumer drift", "compatibility review", and "contract review". Performs an architecture-led review of semantic, backward, forward, and mixed-version compatibility; named interface classes are a minimum, never an exhaustive boundary.
Use when auditing and fixing logic bugs in a scope — off-by-one, wrong operator, inverted condition, unhandled boundary cases, unit/dimension mismatch, code that doesn't do what its name or docstring claims. Triggers on "audit correctness", "fix logic bugs", "check for off-by-one", "correctness review".
Use when auditing and fixing end-to-end data integrity in a scope — invariant violations, partial or conflicting writes, unsafe migrations/backfills, duplicate or reordered effects, precision or time corruption, stale derived stores, broken retention/deletion, and unrecoverable drift. Triggers on "audit data integrity", "review data consistency", "check migrations and invariants", "find data corruption", and related requests. Named risks are minimum, never exhaustive.
Use when auditing and fixing error handling in a scope — swallowed exceptions, defaults returned on error, optional chaining masking missing data, floating promises / missing awaits, entry points with no error boundary, resource leaks on error paths. Triggers on "audit error handling", "hunt silent failures", "fix swallowed errors", "check error boundaries", "missing await".
| name | commit |
| description | Use when the user asks to commit, create a git commit, checkpoint changes, save work to git, or write a commit message. |
Invoking this skill is the authorization to commit. What it adds is the check that the staged set, branch, and message are intentional first.
Check git diff --cached (staged) against git diff HEAD (full worktree) before composing the message. When they diverge, the pre-existing index is likely residue from an aborted hook, rebase leftover, or another agent's partial stage — treat it as suspect, not yours, until confirmed. Stage whole files (git add <path>); partial-hunk staging orphans fixer output into the index if the commit is aborted later. One gotcha: a path-scoped git commit -- <paths> (git's --only mode) restores the pre-hook index on success and drops any fixer re-staging — follow such commits with git reset -q -- <paths> to clear it.
Changes don't match branch name (auth changes on feature/geo-optimization) → likely wrong branch, confirm w/ user before committing.
!cat "${CLAUDE_SKILL_DIR}/../conventional-commits.md"
Capture intent, not implementation. Can't write a focused message → the commit spans unrelated changes, split it.