Skip to content

Block AI attribution trailers in commit messages - #1

Merged
yimsemin merged 1 commit into
mainfrom
chore/block-claude-trailer
Aug 30, 2026
Merged

yimsemin merged 1 commit into
mainfrom
chore/block-claude-trailer

Conversation

@yimsemin

Copy link
Copy Markdown
Owner

목적

Claude co-author 트레일러가 커밋 메시지에 들어가는 것을 하드 게이트로 차단한다.

변경

  • .githooks/commit-msg — 줄 전체가 Co-authored-by: Claude … 또는 🤖 Generated with …인 경우만 제거. 예시로 문자열을 언급하는 본문 줄은 보존. 모든 커밋 경로에서 실행(--no-verify로만 우회).
  • .claude/settings.json — includeCoAuthoredBy: false, attribution 비움.
  • AGENTS.md — 저장소 및 배포 절에 금지 규칙 명시.

활성화 (클론마다 1회)

```
git config core.hooksPath .githooks
```

검증

임시 메시지 파일에 트레일러 3줄 + 문자열을 예시로 쓴 bullet을 넣고 훅 직접 실행 → 트레일러 3줄과 꼬리 빈 줄만 제거, 예시 bullet 보존 확인.
node --check app.js && node --check sw.js, manifest/settings JSON 파싱, git diff --check 통과.

원격 히스토리(main의 기존 17개 트레일러 커밋) 정리는 별도로 승인 후 진행.

Add .githooks/commit-msg as a hard gate that strips "Co-authored-by:
Claude …" and "🤖 Generated with …" lines from every commit message
(commit -m, editor, amend, cherry-pick, revert; --no-verify bypasses).
It removes only lines that are entirely a trailer, so body text that
mentions the string as an example is left intact.

Activate with: git config core.hooksPath .githooks

.claude/settings.json disables Claude Code's own co-author trailer.
AGENTS.md now states the rule under 저장소 및 배포.
@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Aug 30, 2026 •

Copy link
Copy Markdown

Deploying wakeup with  Cloudflare Pages  Cloudflare Pages

Latest commit: cdc7531
Status: ✅  Deploy successful!
Preview URL: https://1d2d0c00.wakeup-1tj.pages.dev
Branch Preview URL: https://chore-block-claude-trailer.wakeup-1tj.pages.dev

View logs

@yimsemin
yimsemin merged commit f6191ac into main Aug 30, 2026
2 checks passed
@yimsemin
yimsemin deleted the chore/block-claude-trailer branch August 30, 2026 08:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant