一键导入
committing-changes
Use when the user asks to commit, says "/commit", or you are about to create a git commit and want a quality gate before it lands.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Use when the user asks to commit, says "/commit", or you are about to create a git commit and want a quality gate before it lands.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Use when setting up these dotfiles on a fresh machine (macOS or Linux), bootstrapping a new dev box, validating a dotfiles install, or debugging a degraded shell after cloning (missing p10k prompt, "command not found: pyenv", "unknown option: --zsh", fd/bat not found, lazygit ignoring config).
Use when asked to merge a pull request ("merge PR
| name | committing-changes |
| description | Use when the user asks to commit, says "/commit", or you are about to create a git commit and want a quality gate before it lands. |
Quality-gated commit: review the diff, then create a conventional commit only if the review passes. Fail-fast — a blocking finding stops the commit, nothing is staged.
/commitLoaded at skill invocation. Pass this block verbatim into the rule-reviewer Task prompt under a PROJECT RULES header — the agent enforces these without reading any files itself.
echo "=== CLAUDE.md ==="; cat CLAUDE.md 2>/dev/null || echo "(none)"
echo "=== docs/RULES.md ==="; cat docs/RULES.md 2>/dev/null || echo "(none)"
Gather context
git status --porcelain — what changedgit branch --show-current — current branchgit log --oneline -5 — recent commits for message styleRun linting on the changed files. Lint failure → fix or abort.
Quality review (quality gate) — skip only if the change is trivial/insignificant. Otherwise dispatch these agents in parallel (single message, multiple Task calls), each scoped to the staged/uncommitted diff:
simplifier — complexity, dead code, DRY/duplication, convention violations, over-engineeringskeptic — logic flaws, security, edge cases, error handling, hacky code not addressing the root causerule-reviewer — mechanical anti-patterns (incl. mock/sample data outside tests) plus the auto-injected Project rules block above, pasted into its Task prompt under a PROJECT RULES headerarchitect — only for significant/architectural changes: spec alignment, test coverage, root-cause correctnessIf any agent reports a blocking violation, abort the commit and report the problem clearly. No commit happens.
Commit (only if all checks pass)