pull-request-review — Claude Code skill: staff-level PR review
A skill that reviews a pull request or branch diff: checks the change against the issue, hunts correctness and security defects, and returns prioritized comments.
npx skills add autohandai/code-cli --skill pull-request-review -a claude-codeWhat pull-request-review does
The skill gives the agent a fixed order of work. It pulls the diff first — git_diff for the working tree, git_diff_range against the base branch — and reads all of it before saying anything. Then it opens the linked issue, PR description or commit messages and writes one line about what the change claims to do. Files around the diff get opened too, since a change is only correct in context.
Review order is spelled out: does it do what it says, then correctness (edge cases, error paths, concurrency, ordering, off-by-one, null and empty inputs, resource cleanup, timeouts), then security (injection, path traversal, secrets, permission checks, unsafe deserialization, shell execution with user input), then compatibility (public API, config, storage formats, migrations, older callers), then tests, then maintainability. Where the environment allows, the skill runs tests and lint itself.
Output starts with a one-line verdict: approve, approve with nits, or request changes. Findings follow by severity, each with file:line, what is wrong, why it matters and a concrete fix; blocking items are kept apart from optional ones. The agent also states what it did not review. Everything runs through git and file reads, so a repository with no commit history gives the diff check nothing to work from.
What it helps with
- confirm a PR meets the issue requirements instead of drifting in scope
- catch correctness bugs and cite the exact file and line
- run a security pass over the change before merge
- check whether the edit breaks public API or migrations
- sort blocking findings from optional nits
Example prompts for the agent
- Review the current branch against
mainand give me a verdict - Check this PR: what the issue asks for versus what it changes
- Review my changes and flag security issues with line numbers
How to install pull-request-review
1Skills CLI (Vercel)
npx skills add autohandai/code-cli --skill pull-request-review -a claude-code2Manually: put the files in place
~/.claude/skills/pull-request-review/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/pull-request-review/
1Skills CLI (Vercel)
npx skills add autohandai/code-cli --skill pull-request-review -a codex2Manually: put the files in place
.agents/skills/pull-request-review/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add autohandai/code-cli --skill pull-request-review -a cursor2Manually: put the files in place
.cursor/skills/pull-request-review/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install autohandai/code-cli pull-request-review2Manually: put the files in place
.github/skills/pull-request-review/SKILL.md1Skills CLI (Vercel)
npx skills add autohandai/code-cli --skill pull-request-review -a gemini-cli2Platform CLI
gemini skills install https://github.com/autohandai/code-cli --path src/skills/builtin/pull-request-reviewManually: put the files in place
.devin/skills/pull-request-review/SKILL.mdThe legacy .windsurf/skills/ path still works
Skills CLI (Vercel)
npx skills add autohandai/code-cli --skill pull-request-review -a opencodeClaude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
Step by step, with commands for each platform: How to install skills in Claude Code: five ways
Questions about pull-request-review
How do I install pull-request-review in Claude Code?
Run npx skills add autohandai/code-cli --skill pull-request-review -a claude-code. The skill lands at ~/.claude/skills/pull-request-review/SKILL.md.
What does pull-request-review do?
It reads a pull request or branch diff and returns ranked comments: whether the issue requirements are met, correctness and security defects, test coverage and compatibility.
Which platforms support the skill?
Claude, Codex, Cursor, GitHub Copilot, Gemini CLI and OpenCode, each with its own install path.
Source text
SKILL.md · Apache-2.0
--- name: pull-request-review description: Review a pull request or branch diff like a staff engineer. Verify it does what the issue asks, find correctness and security defects with file and line evidence, check tests and compatibility, and deliver prioritized, actionable comments. Use for PR review, branch review, and "review my changes". allowed-tools: read_file find_grep fff_find list_tree git_status git_diff git_diff_range git_log run_command code_review --- # Review the change, not the style guide A useful review finds the defect that would have shipped and explains it so the author can fix it in one pass. ## Establish scope 1. Get the diff (`git_diff` for the working tree, `git_diff_range` against the base branch). Read the whole diff before commenting on any part. 2. Read the linked issue, PR description, or commit messages. Write one line stating what the change claims to do. 3. Open the files around the diff; a change is only correct in context. ## Check in this order 1. **Does it do what it says**: every requirement from the issue is met, no silent scope changes, no leftover debug code or TODOs. 2. **Correctness**: edge cases, error paths, concurrency, ordering, off-by-one, null and empty inputs, resource cleanup, timeouts. 3. **Security**: injection, path traversal, secrets, permission checks, unsafe deserialization, shell execution with user input. 4. **Compatibility**: public API, config, storage formats, migrations, feature flags, older callers. 5. **Tests**: a test fails before and passes after for each fix; new behavior has coverage including edge cases; flaky patterns (sleeps, real network). 6. **Maintainability**: naming, duplication, module boundaries, comments only where logic is non-obvious. Run the tests and lint yourself when the environment allows; a review with evidence beats one with opinions. ## Deliver - Verdict first: approve, approve with nits, or request changes, in one line. - Findings ordered by severity. Each: file:line, what is wrong, why it matters, a concrete fix. Mark confidence when you could not verify. - Separate blocking from optional. Keep nits short or drop them. - Say what you did not review.
© autohandai · Apache-2.0 · autohandai/code-cli