Review PR
Review a pull request for bugs, regressions, missing tests, and risky changes.
When explicitly invoked with extra text, treat that text as the PR number or URL. If no PR
reference is provided, infer it from the current branch.
Process
Preferred execution
- If subagents are available, use
github-dev:pr-reviewer and pass the PR reference.
- Otherwise follow the manual steps below.
Parse PR reference
- If a PR number or URL is provided, extract owner, repo, and PR number.
- If not, auto-detect the PR from the current branch with
gh pr view --json number,headRefName.
Fetch PR data
- Use
gh pr diff <number> for the full diff.
- Use
gh pr view <number> --json files for the changed file list.
- Skip generated or vendored files such as
.lock, .min.js, .min.css, dist/, build/, vendor/, node_modules/, _pb2.py, and images.
Review focus
- Only report issues that require fixes.
- Only review PR changes, never pre-existing issues in unchanged code.
- Prioritize bugs, security issues, breaking changes, performance issues, edge cases, and missing tests.
- Combine related issues that share the same root cause.
- Keep the list short and high signal.
Review comment rules
- Only create pending PR comments, never submit or confirm the review automatically.
- Use
gh for GitHub operations.
- Start comments in lowercase, keep them short, avoid end punctuation when possible.
- Use simple language for both bot-facing and human-facing comments.
Output Format
If issues are found, report them in descending severity with file references and a final
recommendation of NEEDS_CHANGES.
If no issues are found, return APPROVE - No fixes required.
1---2name: review-pr-23description: This skill should be used when user asks to "review a PR", "review pull request", "review this pr", "code review this PR", "check PR4---5
6# Review PR
7
8Review a pull request for bugs, regressions, missing tests, and risky changes.
9
10When explicitly invoked with extra text, treat that text as the PR number or URL. If no PR
11reference is provided, infer it from the current branch.
12
13## Process
14
151. **Preferred execution**
16 - If subagents are available, use `github-dev:pr-reviewer` and pass the PR reference.
17 - Otherwise follow the manual steps below.
18
192. **Parse PR reference**
20 - If a PR number or URL is provided, extract owner, repo, and PR number.
21 - If not, auto-detect the PR from the current branch with `gh pr view --json number,headRefName`.
22
233. **Fetch PR data**
24 - Use `gh pr diff <number>` for the full diff.
25 - Use `gh pr view <number> --json files` for the changed file list.
26 - Skip generated or vendored files such as `.lock`, `.min.js`, `.min.css`, `dist/`, `build/`, `vendor/`, `node_modules/`, `_pb2.py`, and images.
27
284. **Review focus**
29 - Only report issues that require fixes.
30 - Only review PR changes, never pre-existing issues in unchanged code.
31 - Prioritize bugs, security issues, breaking changes, performance issues, edge cases, and missing tests.
32 - Combine related issues that share the same root cause.
33 - Keep the list short and high signal.
34
355. **Review comment rules**
36 - Only create pending PR comments, never submit or confirm the review automatically.
37 - Use `gh` for GitHub operations.
38 - Start comments in lowercase, keep them short, avoid end punctuation when possible.
39 - Use simple language for both bot-facing and human-facing comments.
40
41## Output Format
42
43If issues are found, report them in descending severity with file references and a final
44recommendation of `NEEDS_CHANGES`.
45
46If no issues are found, return `APPROVE - No fixes required`.