git-commits

git-commits

熱門

Git Commit 規範

3940星標
303分支
更新於 2026/1/26
SKILL.md
唯讀
名稱
git-commits
描述

Git Commit 規範

Git Commit 規範

當使用者要求提交 (commit)、推送 (push) 或儲存變更至 Git 時:

必須使用 /commit 技能

切勿直接執行 git commit。請改用:

Skill("commit")

/commit 技能會:

  1. 從 commit 中移除 Claude 署名
  2. 產生 reasoning.md 以記錄嘗試過的內容
  3. 清除建置嘗試記錄,以利下一個功能開發

為什麼這很重要

  • 一般的 git commit 會加上 "Generated with Claude Code" 與 Co-Author 資訊列
  • /commit 技能會移除這些內容,使 commit 看起來是由使用者親自撰寫
  • 思考記錄 (Reasoning capture) 能為未來的對話保留建置歷史紀錄

觸發字詞

當你在使用者提示詞中看到以下字詞時,請使用 commit 技能:

  • "commit", "push", "save changes"
  • "push to github", "push changes"
  • "commit and push"

Commit 完成後

該技能會提示你執行:

bash "$CLAUDE_PROJECT_DIR/.claude/scripts/generate-reasoning.sh" <hash> "<message>"

若使用者要求推送,請接著執行:

git push origin <branch>