Skip to content

Commit de4ba0e

Browse files
authored
docs: add the v2.19.2 changes and the kernel's Assisted-by decision (#58)
1 parent fb80e01 commit de4ba0e

7 files changed

Lines changed: 116 additions & 18 deletions

File tree

‎docs/blog/posts/ai-commit-attribution-policy.md‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ source has already given three different answers.
3636
| Position | Who takes it |
3737
|---|---|
3838
| No AI trailers in the history; disclose in the pull request instead | [Kubernetes](https://www.kubernetes.dev/docs/guide/pull-requests/) |
39-
| AI is welcome, but say so with a trailer, and never credit the tool as a person | [Linux kernel](https://docs.kernel.org/process/coding-assistants.html) and [Fedora](https://docs.fedoraproject.org/en-US/council/policy/ai-policy/) (`Assisted-by:`) |
39+
| AI is welcome, but say so with a trailer, and never credit the tool as a person | [Fedora](https://docs.fedoraproject.org/en-US/council/policy/ai-policy/) (`Assisted-by:`), and the [Linux kernel](https://docs.kernel.org/process/coding-assistants.html) until its maintainers decided in October 2026 to drop the tag |
4040
| The tool can be credited as a co-author | [pytest](https://docs.pytest.org/en/stable/contributing.html) (`Co-authored-by:`) and the [ASF](https://www.apache.org/legal/generative-tooling.html) (`Generated-by:` or `Co-authored-by:`) |
4141

4242
The kernel adds one hard rule on top: an AI agent must never add a
@@ -99,7 +99,8 @@ The detection covers co-author and sign-off lines that name Claude Code, GitHub
9999
Copilot, Codex, Gemini, Cursor, Devin, Aider, Windsurf, Tabby or a model, and
100100
vendor marks such as "Generated with Claude Code";
101101
[v2.19.0](../../changelog.md#v2190) added Amp, OpenHands, Factory Droid and
102-
Jules. It matches the tools'
102+
Jules, and [v2.19.2](../../changelog.md#v2192) the Copilot coding agent's
103+
`Agent-Logs-Url:` trailer. It matches the tools'
103104
noreply addresses, so a human co-author who happens to be called Claude is left
104105
alone. [CC013](../../rules.md#cc013) keeps the current list.
105106

‎docs/changelog.md‎

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ below and to the page that documents the feature properly.
1111

1212
| Version | What changed | Documented in |
1313
|---|---|---|
14+
| [2.19.2](#v2192) | Copilot coding agent commits recognised; config values of the wrong type refused; commit text printed inert | [CC013](rules.md#cc013) · [Every option](configuration.md#every-option) · [Color and links](example.md#color-and-links) |
1415
| [2.19.1](#v2191) | `develop` accepted by default; stricter merge-subject, fixup, WIP and sign-off checks | [CC201](rules.md#cc201) · [CC001](rules.md#cc001) · [CC009](rules.md#cc009) |
1516
| [2.19.0](#v2190) | Branch descriptions held to the Conventional Branch grammar; Amp, OpenHands, Factory Droid and Jules recognised | [CC201](rules.md#cc201) · [CC013](rules.md#cc013) |
1617
| [2.18.3](#v2183) | `--fix` corrects a message in place; `--branch` reads GitLab, Bitbucket, Azure and Jenkins variables | [Fixing a message in place](example.md#fixing-a-message-in-place) · [Other CI](guides/other-ci.md) |
@@ -32,6 +33,59 @@ below and to the page that documents the feature properly.
3233
| [2.5.0](#v250) | Organization-wide config with `inherit_from` | [Across an organization](guides/organization.md) |
3334
| [2.0.0](#v200) | Configuration moved from YAML to TOML — breaking | [Migrating from v1](migration.md) |
3435

36+
## v2.19.2 (2026-10-18) { #v2192 }
37+
38+
### Changed
39+
40+
* **A config value of the wrong type stops the run** — `message_pattern = 5`
41+
crashed, `subject_max_length = true` became a one-character limit,
42+
`subject_max_length = "50"` turned the rule off without a word, and
43+
`allow_commit_types = "feat,fix"` was read letter by letter, so `f: x`
44+
passed. A pattern, a subject length, or a type or name list of the wrong
45+
type is now a configuration error (exit 2) that names the setting. A
46+
comma-separated string in `allow_commit_types`, `allow_branch_types` or
47+
`allow_branch_names` is split the way `--allow-commit-types` splits it. A
48+
config that relied on the old reading now stops with that error, so check
49+
yours when you upgrade.
50+
See PR [#624](https://github.com/commit-check/commit-check/pull/624) and
51+
[Every option](configuration.md#every-option).
52+
53+
* **[CC202](rules.md#cc202) skips when the rebase target does not resolve** —
54+
a `require_rebase_target` that matched no branch, because of a typo or a
55+
shallow clone without `origin/main`, reported a pass without comparing
56+
anything. It is now a skip, and the JSON `reason` names the missing target.
57+
The exit code stays 0.
58+
See PR [#617](https://github.com/commit-check/commit-check/pull/617).
59+
60+
* **[CC401](rules.md#cc401) checks the tag name the remote receives** — in a
61+
`pre-push` hook, `git push origin v1.0.0:refs/tags/bad-name` was checked as
62+
`v1.0.0`, so `bad-name` reached the remote. The remote name is checked now.
63+
See PR [#615](https://github.com/commit-check/commit-check/pull/615).
64+
65+
### Fixed
66+
67+
* **[CC013](rules.md#cc013)–[CC016](rules.md#cc016) recognise the Copilot
68+
coding agent** — its commits carry an `Agent-Logs-Url:` trailer, and a
69+
squash merge of its pull request adds a `copilot-swe-agent[bot]` co-author
70+
line. Both passed `forbid` and `disclose`. They are now read as GitHub
71+
Copilot, and under `disclose` the correction appends
72+
`Assisted-by: GitHub Copilot`.
73+
See PR [#632](https://github.com/commit-check/commit-check/pull/632).
74+
75+
* **Commit text is printed inert** — a failing message, branch or tag name was
76+
printed as written, so escape sequences reached the terminal, and a body
77+
line starting with `::` reached a GitHub Actions runner as a workflow
78+
command. Text output now shows control characters as `\xNN` and puts a
79+
backslash before such a `::`. `--format json` is unchanged.
80+
See PR [#620](https://github.com/commit-check/commit-check/pull/620) and
81+
[Color and links](example.md#color-and-links).
82+
83+
* **Three patterns run in linear time** — the CC001 header correction and the
84+
AI trailer matching could take seconds on a line padded with spaces.
85+
Verdicts are unchanged, except that a `Co-authored-by:` line with an empty
86+
name before `(aider)` no longer counts.
87+
See PR [#626](https://github.com/commit-check/commit-check/pull/626).
88+
3589
## v2.19.1 (2026-10-16) { #v2191 }
3690

3791
### Changed

‎docs/configuration.md‎

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -351,7 +351,26 @@ setting in the file appears to have no effect.
351351

352352
## Every option
353353

354-
Types are as TOML understands them. A default shown as `""` means the option is
354+
Types are as TOML understands them. A pattern, a subject length, or a type or
355+
name list given a value of another type stops the run with exit 2 and names
356+
the setting:
357+
358+
```toml title="cchk.toml"
359+
[commit]
360+
subject_max_length = "50"
361+
```
362+
363+
```console
364+
$ echo "feat: add streaming support" | commit-check -m
365+
Error: [commit] subject_max_length must be a whole number, got '50'
366+
```
367+
368+
`allow_commit_types`, `allow_branch_types` and `allow_branch_names` also take
369+
one comma-separated string, as `--allow-commit-types` does. A boolean has to be
370+
a TOML boolean: `"false"` in quotes is a non-empty string, and it counts as
371+
true.
372+
373+
A default shown as `""` means the option is
355374
unset, which is never the same as the check being off — but it does not mean
356375
the same thing twice, so read the description rather than the cell:
357376

‎docs/example.md‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -237,6 +237,12 @@ To override the detection:
237237
| `FORCE_COLOR=1` / `FORCE_COLOR=0` | color on or off, outranking everything else |
238238
| `FORCE_HYPERLINK=1` / `FORCE_HYPERLINK=0` | linked rule IDs on or off |
239239

240+
Whatever the destination, the commit text in a failure is printed inert.
241+
Control characters other than newline and tab appear as `\xNN`, and a line
242+
that starts with `::` is printed as `\::`, so a commit message cannot move the
243+
terminal's cursor or send a GitHub Actions runner a workflow command.
244+
`--format json` is not affected; JSON escapes those characters already.
245+
240246
### Checking a range of commits
241247

242248
`--rev` makes each commit addressable without checking it out or piping its

‎docs/guides/policies.md‎

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -134,15 +134,18 @@ Docs: https://commit-check.com/rules/#cc013
134134
Recognised signatures are co-author and sign-off lines naming Claude Code,
135135
GitHub Copilot, Codex, Gemini, Cursor, Devin, Aider, Windsurf, Tabby, Amp,
136136
OpenHands, Factory Droid and Jules, the disclosure trailers `Assisted-by:` and
137-
`Generated-by:`, vendor marks such as `🤖 Generated with Claude Code` and
138-
Amp's `Amp-Thread-ID:`, and generic AI model names. This is the
137+
`Generated-by:`, vendor marks such as `🤖 Generated with Claude Code`, Amp's
138+
`Amp-Thread-ID:` and the Copilot coding agent's `Agent-Logs-Url:`, and generic
139+
AI model names. This is the
139140
position [Kubernetes](https://www.kubernetes.dev/docs/guide/pull-requests/)
140141
takes — no AI trailers in the history, disclosure in the pull request
141142
instead.
142143

143144
These rules read only the message. Jules and OpenHands can commit under their
144145
own bot identity instead of adding a co-author line, and such a commit passes
145-
when its message contains no recognized AI signature.
146+
when its message contains no recognized AI signature. The Copilot coding agent
147+
also commits as its own account, but every commit it makes carries an
148+
`Agent-Logs-Url:` trailer, so its commits are caught.
146149

147150
!!! warning "This checks disclosure, not authorship"
148151

@@ -157,12 +160,13 @@ when its message contains no recognized AI signature.
157160

158161
### Asking for disclosure instead
159162

160-
Most projects that allow AI assistance ask to be told about it. The
161-
[Linux kernel](https://docs.kernel.org/process/coding-assistants.html),
163+
Most projects that allow AI assistance ask to be told about it.
162164
[Fedora](https://docs.fedoraproject.org/en-US/council/policy/ai-policy/) and
163-
FluxCD want an `Assisted-by:` trailer; the
165+
FluxCD want an `Assisted-by:` trailer, as the
166+
[Linux kernel](https://docs.kernel.org/process/coding-assistants.html) did
167+
until its maintainers decided in October 2026 to drop the tag; the
164168
[Apache Software Foundation](https://www.apache.org/legal/generative-tooling.html)
165-
recommends `Generated-by:`. The kernel also says an AI agent must
169+
recommends `Generated-by:`. The kernel still says an AI agent must
166170
never add a `Signed-off-by:` line, because only a person can certify the
167171
[DCO](https://developercertificate.org/).
168172

@@ -202,7 +206,7 @@ as the project's disclosure trailer, keeping the name the tool gave itself.
202206
```
203207

204208
Once the tool is disclosed, CC015 asks only for the co-author line to go, and
205-
a commit written the way the kernel asks passes all three:
209+
a commit in the kernel's `Assisted-by:` format passes all three:
206210

207211
```bash
208212
printf 'feat: add caching layer\n\nAssisted-by: LLM coccinelle sparse\nSigned-off-by: Jane Dev <jane@example.com>' | commit-check -m
@@ -216,7 +220,7 @@ and the first one is what a correction is written with:
216220
```toml title="cchk.toml"
217221
[commit]
218222
ai_attribution = "disclose"
219-
ai_disclosure_trailers = ["Assisted-by"] # the kernel's, and nothing else
223+
ai_disclosure_trailers = ["Assisted-by"] # Assisted-by, and nothing else
220224
```
221225

222226
Listing `Co-authored-by` says the project accepts the tool as a co-author —

‎docs/rules.md‎

Lines changed: 18 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -565,8 +565,11 @@ Rejects a commit whose message carries any AI attribution: a co-author or
565565
sign-off line naming Claude Code, Copilot, Codex, Gemini, Cursor, Devin,
566566
Aider, Windsurf, Tabby, Amp, OpenHands, Factory Droid or Jules, a disclosure
567567
trailer such as `Assisted-by:` or `Generated-by:`, a vendor's own mark such
568-
as `🤖 Generated with Claude Code` or Amp's `Amp-Thread-ID:` trailer, and
569-
generic AI model names.
568+
as `🤖 Generated with Claude Code`, Amp's `Amp-Thread-ID:` trailer or the
569+
`Agent-Logs-Url:` trailer the Copilot coding agent adds, and generic AI model
570+
names. Copilot is also recognised by its account's
571+
`N+Copilot@users.noreply.github.com` address, so the coding agent's
572+
`copilot-swe-agent[bot]` co-author line counts under any display name.
570573

571574
**Why is this bad?**
572575

@@ -606,10 +609,11 @@ match `ai_disclosure_pattern` — fails too.
606609
**Why is this bad?**
607610

608611
A project that allows AI assistance and asks for it to be disclosed has an
609-
honour-system rule until something checks it. The
610-
[Linux kernel](https://docs.kernel.org/process/coding-assistants.html),
612+
honour-system rule until something checks it.
611613
[Fedora](https://docs.fedoraproject.org/en-US/council/policy/ai-policy/) and
612-
FluxCD ask for `Assisted-by:`; the
614+
FluxCD ask for `Assisted-by:`, as the
615+
[Linux kernel](https://docs.kernel.org/process/coding-assistants.html) did
616+
until its maintainers decided in October 2026 to drop the tag; the
613617
[Apache Software Foundation](https://www.apache.org/legal/generative-tooling.html)
614618
recommends `Generated-by:`. The tools, meanwhile, stamp their own format on
615619
the way out, so a contributor following the policy and one ignoring it produce
@@ -855,6 +859,11 @@ that git can create as a branch.
855859

856860
Checks that the current branch is rebased onto a target branch.
857861

862+
When the target matches no branch, neither locally nor under `origin/`, the
863+
check is a **skip**, not a pass, and the JSON `reason` says
864+
`rebase target 'main' not found`. A shallow CI clone without the target branch
865+
is the usual cause; fetch the branch before the check.
866+
858867
**Why is this bad?**
859868

860869
A branch that has fallen behind is tested against code that no longer exists on
@@ -1023,6 +1032,10 @@ and `release-1.2.3` do not.
10231032
A commit with no tag is a **skip**, not a failure: the rule governs how tags
10241033
are named, and the absence of one is not a naming violation.
10251034

1035+
As a `pre-push` hook it checks the tags the push creates, under the name the
1036+
remote will give them: `git push origin v1.0.0:refs/tags/release-1` is checked
1037+
as `release-1`. Deleting a tag is not checked.
1038+
10261039
**Why is this bad?**
10271040

10281041
Tags are the public interface of a release. Package managers, changelog

‎docs/troubleshoot.md‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ broken policy from a bad commit. Commit Check keeps them apart:
107107
|---|---|
108108
| `0` | Every enforced check passed, or every check was skipped. |
109109
| `1` | A check failed. This is a verdict on the commit. |
110-
| `2` | The run could not start, so nothing was validated: bad usage, a `--rev` that does not resolve, a setting whose regex does not compile, or a config file that is missing, is not valid TOML, or names an unknown rule. |
110+
| `2` | The run could not start, so nothing was validated: bad usage, a `--rev` that does not resolve, a setting whose regex does not compile or whose value has the wrong type, or a config file that is missing, is not valid TOML, or names an unknown rule. |
111111

112112
A configuration error names the file it came from:
113113

@@ -120,6 +120,7 @@ instead, and echoes the value it could not use:
120120

121121
```text
122122
Error: [commit] message_pattern is not a valid regex: '^(unclosed' (missing ), unterminated subpattern at position 1)
123+
Error: [commit] subject_max_length must be a whole number, got '50'
123124
```
124125

125126
## Something else

0 commit comments

Comments
 (0)