✨ feat: P-33 onboard warns about a CODEOWNERS naming the owner, 0.5.4

Merged
AT
1mo ago
+306-8

Slice: #75

Once the agent authors a client's pull requests, a CODEOWNERS rule naming the owner (* @owner) makes GitHub ask the owner to review every agent pull request, shown as coming from the agent, because GitHub never asks a pull request's author. onboard said nothing about it.

  • src/codeowners.ts: reads the CODEOWNERS file GitHub uses (the first of .github/CODEOWNERS, CODEOWNERS, docs/CODEOWNERS) and finds the rules naming the owner from .github/process-rules.json, in any case. Removing the owner drops the handle with the space before it, and drops a rule left with no owners. Team handles (even @org/<owner>), other owners, emails, whole-line and trailing comments, escaped \# patterns and CRLF line endings stay.

  • onboard (identity, so every client): after the Claude settings, it says which rules name the owner and why that matters, and asks Remove <owner> from those rules in <file>[, and drop the rule left with no owners]? [y/N]. No (the default) leaves the file and onboard goes on; yes writes it and the closing line names it among the files to commit.

  • doctor, run in an adopting repo whose settings name the agent, warns about the same rules and names onboard as the fix; it changes nothing and still passes.

  • Tests: src/codeowners.test.ts, plus onboard (yes, no, default, no match) and doctor; coverage stays above the gates. README and docs/decisions.md (the owner's "OK." of 2026-11-01). Version 0.5.4 in package.json and the README install line (0.5.3 is #74's).

  • This repo's own checks move from checks.yml@v0.5.0 to @v0.5.2 (same template, both version lines), so its Work rules count the owner's 👍 on a proposal (P-20, shipped in 0.5.2). At v0.5.0 only a Decision: comment counted.

After merge, tag v0.5.4 on the merge commit.

🤖 Generated with Claude Code