diff --git a/.github/workflows/claude.yml b/.github/workflows/claude.yml index 4116680..91d4d68 100644 --- a/.github/workflows/claude.yml +++ b/.github/workflows/claude.yml @@ -41,10 +41,12 @@ jobs: with: claude_code_oauth_token: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }} use_commit_signing: true - # The action's default bot_id (41898282) is github-actions[bot]'s ID, - # so commits were attributed to the wrong account. 209825114 is the - # real claude[bot] user ID; with it the commit author email becomes - # 209825114+claude[bot]@users.noreply.github.com and GitHub shows - # Claude's avatar in commits and the Contributors graph. - bot_id: "209825114" - bot_name: "claude[bot]" \ No newline at end of file + # Author commits as the repository owner, matching how local + # Claude Code commits look. Claude is credited through the + # "Co-Authored-By: Claude " trailer required + # by CLAUDE.md, which attributes the official `claude` account + # (no [bot] suffix) in the Contributors graph. + # Note: the action's default bot_id (41898282) is github-actions[bot], + # which misattributes commits - always set bot_id/bot_name explicitly. + bot_id: "5227952" + bot_name: "AlanHuang168" \ No newline at end of file diff --git a/CLAUDE.md b/CLAUDE.md index 7734524..fa002de 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -7,3 +7,14 @@ Before starting any development task: 3. Read `core/skills//SKILL.md` for the active stage. 4. Follow `core/rules/`. 5. Do not bypass stage gates, verification rules, or Git restrictions. + +## Git commit attribution + +End every commit message with this trailer on its own line: + +```text +Co-Authored-By: Claude +``` + +This credits the official `claude` GitHub account as co-author so AI +contributions stay visible in the Contributors graph.