Skills · skills/cad-pr-review/SKILL.md · Markdown

Pull request review

An author cannot review their own change: they read what they meant, not what they wrote. Every PR gets a review by an agent or person that did not write it, and the review lives on the PR, where anyone can see it later.

As the author

  1. Make the PR reviewable. Description: what and why, how it was checked (commands and their results, the real project it was tried on, renders or reports), effect on other projects, and Closes #<issue>. For geometry changes, run cad-agent all first. Every row passes, "Holes clear" included, and you have walked docs/common-issues.md. Push everything; the reviewer reads GitHub and the branch, not your session.

  2. Ask for the review. In Claude Code, spawn the cad-pr-reviewer subagent with the PR URL and the checkout path. In Codex, start a separate session with the cad-pr-reviewer skill. Give it the PR, not your conclusions: a reviewer told what to find tends to find it.

  3. Answer every comment on the PR. Fix it and reply with the commit (Fixed in <sha>: ...), or explain why not. Then resolve the thread:

    gh api repos/<owner>/<repo>/pulls/<n>/comments/<comment_id>/replies -f body="Fixed in <sha>: ..."
    gh api graphql -f query='mutation{resolveReviewThread(input:{threadId:"<thread id>"}){thread{isResolved}}}'
    # thread ids: gh api graphql -f query='query{repository(owner:"<o>",name:"<r>"){pullRequest(number:<n>)
    #   {reviewThreads(first:50){nodes{id isResolved comments(first:1){nodes{databaseId body}}}}}}}'
    
  4. Merge only under the repo's rules: CI green, a review exists, every thread resolved, and the user's go-ahead where the repo requires it (cad-agent: the user asks; product repos say in their AGENTS.md). Merge commits, not squash, unless the repo says otherwise. After the merge, check that the linked issues closed and tick the tracking issue (cad-work-tracking).

As the reviewer