Skip to content

Block tool/AI attribution in commits, tags and PRs - #13

Merged
HA-HUB-I merged 1 commit into
mainfrom
chore/attribution-guard
Oct 28, 2026
Merged

HA-HUB-I merged 1 commit into
mainfrom
chore/attribution-guard

Conversation

@HA-HUB-I

Copy link
Copy Markdown
Collaborator

Summary

Rule for everything that reaches GitHub: no co-author trailers, no tool "generated" footers and no assistant name in commit messages, annotated tags, PR titles or PR descriptions. Otherwise the tool appears in the repository contributors list.

Enforced at three levels:

  1. commit-msg hook rejects the commit.
  2. pre-push hook rejects the push if any new commit or annotated tag has it.
  3. CI job (part of QA) checks new commits plus this PR's title/description, so it also covers people without the hooks. It re-runs when the PR is edited.

Hooks are enabled automatically by composer install (core.hooksPath = bin/git-hooks), or manually with composer hooks.

Test plan

  • Checker: clean message passes; co-author trailer, tool footer and assistant name are blocked; git # comment lines ignored
  • commit-msg hook blocked a test commit with a co-author trailer
  • pre-push hook allowed this branch push
  • main history since v1.1.0 and PR Release 1.1.1: WP.org QA gate (WPCS, PHPStan, Plugin Check) + fixes #12 are clean
  • QA green on this PR (including the new job)

Commit messages, annotated tags and PR text must not carry co-author
trailers, tool footers or the assistant's name, so no tool ends up in
the repository contributors list.

- bin/check-attribution.sh: shared checker (message file, revision
  range or stdin text)
- bin/git-hooks/commit-msg and pre-push reject offending commits and
  annotated tags; enabled by composer install / composer hooks
  (core.hooksPath)
- ci.yml: new attribution job checks new commits plus the PR title and
  description, re-run when the PR is edited
- composer attribution-check is part of composer qa
@HA-HUB-I
HA-HUB-I merged commit 7d15d37 into main Oct 28, 2026
11 checks passed
@HA-HUB-I
HA-HUB-I deleted the chore/attribution-guard branch October 28, 2026 11:35
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