
























commit-msg hook · github action
A commit-msg hook and GitHub Action that rejects commits carrying AI attribution trailers — because the byline is the one place accountability can’t be shared.
$ pre-commit install --hook-type commit-msg
COMMIT_EDITMSG ~/work · 9f2c1ab
1feat: add a retry budget to the sync worker
3Author: Ada Lovelace <ada@example.com>
4Signed-off-by: Ada Lovelace <ada@example.com>
5Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
6Claude-Session: https://claude.ai/code/session_01T…
2 trailers removed
@@ why @@
the manifesto
AI co-author git-commit bylines are an impressive marketing hook — but they provide no useful signal of provenance.
It is mid-2026. All code written is facilitated by a host of sophisticated tools. The most recent of these are AI ‘co-authors.’ These have incredible utility, but — as with the other tools in the development toolchain — they are not meaningfully accountable for their output.
At best, tagging the bot that generated code as a ‘co-author’ adds noise to the single most important accountability and attribution mechanism in the development hierarchy. At worst, the practice implies similarly diffused responsibility.
As much as the act of code authorship is changing, the social rules for authorship must not slip: we are responsible for our contributions.
The ‘author’ is, as ever, the contributing person.
Remove corporate spam from commit messages.
— No AI co-authors.
@@ diff @@
what it catches
Matching runs on both the display name and the email, normalized — so a renamed bot
or a numeric noreply address doesn’t slip through. A human is
never in the blast radius.
# the commit will not be created
-Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
-Claude-Session: https://claude.ai/code/…
-Co-authored-by: Copilot <copilot@github.com>
-Co-authored-by: Cursor <cursoragent@cursor.com>
-Co-authored-by: aider <aider@aider.chat>
ChatGPTGPTCodex GeminiDevinWindsurf OpenCodeAmazon QLlama MistralDeepSeekQwen GrokCodyCodeium ClineTabnine+ more
# the commit goes through, untouched
+Co-authored-by: Claude Shannon <claude.shannon@example.com>
+Co-authored-by: Grace Hopper <grace@example.com>
+Signed-off-by: Ada Lovelace <ada@example.com>
## commented lines are ignored, too
It blocks the bot named Claude.
It welcomes the human named Claude Shannon.
@@ use @@
install
1.0.0. Pick your hook manager.Every path points at the public repo and a tagged release, so installs are repeatable. Swap the tag when you upgrade.
Add the repo to .pre-commit-config.yaml, then install the commit-msg stage.
.pre-commit-config.yaml
default_install_hook_types: [pre-commit, commit-msg]
repos:
- repo: https://github.com/GoodHatsLLC/no-ai-coauthors
rev: 1.0.0
hooks:
- id: no-ai-coauthors
terminal
$ pre-commit install --hook-type commit-msg
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。