review-pr

$npx mdskill add fcakyon/claude-codex-settings/review-pr

Reviews a GitHub pull request for bugs and risky changes.

  • Solves the need to get a code review on a pull request.
  • Depends on GitHub CLI and optionally a subagent skill.
  • Parses PR reference from user input or current branch.
  • Returns a concise list of issues requiring fixes.

SKILL.md

.github/skills/review-prView on GitHub ↗
---
name: review-pr
description: This skill should be used when user asks to "review a PR", "review pull request", "review this pr", "code review this PR", "check PR #N", provides a GitHub PR URL, or explicitly invokes "review-pr".
---

# 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

1. **Preferred execution**
   - If subagents are available, use `github-dev:pr-reviewer` and pass the PR reference.
   - Otherwise follow the manual steps below.

2. **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`.

3. **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.

4. **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.

5. **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`.

More from fcakyon/claude-codex-settings

SkillDescription
adhd-output-styleThis skill should be used when the user asks for "ADHD output", "fewer output tokens", "short numbered steps", "limited working memory formatting", or explicitly invokes "adhd-output-style".
anthropic-frontend-designGuidance for distinctive, intentional visual design when building new UI or reshaping an existing one. Helps with aesthetic direction, typography, and making choices that don't read as templated defaults.
azure-usageThis skill should be used when user asks to "query Azure resources", "list storage accounts", "manage Key Vault secrets", "work with Cosmos DB", "check AKS clusters", "use Azure MCP", or interact with any Azure service.
clean-gone-branchesThis skill should be used when user asks to "clean gone branches", "remove deleted local branches", "prune branches removed from remote", or explicitly invokes "clean-gone-branches".
commit-stagedThis skill should be used when user asks to "commit these changes", "write commit message", "stage and commit", "create a commit", "commit staged files", or explicitly invokes "commit-staged".
docUse when the task involves reading, creating, or editing `.docx` documents, especially when formatting or layout fidelity matters; prefer `python-docx` plus the bundled `scripts/render_docx.py` for visual checks.
dokploy-deployThis skill should be used when user asks to "deploy with Dokploy", "use Dokploy Cloud", "manage self-hosted Dokploy", "deploy Docker Compose on Dokploy", "manage Dokploy databases", "configure Dokploy domains", or "look up Dokploy CLI commands".
electronAutomate Electron desktop apps (VS Code, Slack, Discord, Figma, Notion, Spotify, etc.) using agent-browser via Chrome DevTools Protocol. Use when the user needs to interact with an Electron app, automate a desktop app, connect to a running app, control a native app, or test an Electron application. Triggers include "automate Slack app", "control VS Code", "interact with Discord app", "test this Electron app", "connect to desktop app", or any task requiring automation of a native Electron application.
fable-advisorThis skill should be used when the user asks for a "Fable second opinion", wants to "check a plan before committing", needs another view after repeated failures, or explicitly invokes "fable-advisor".
gcloud-usageThis skill should be used when user asks about "GCloud logs", "Cloud Logging queries", "Google Cloud metrics", "GCP observability", "trace analysis", or "debugging production issues on GCP".