pr-reviewer
Comprehensive GitHub Pull Request code review skill. Use when asked to "review this PR", "code review", "review pull request", "check this PR", or when a…
от SpillwaveSolutions★ 46 звёзд на GitHub
Установить pr-reviewer в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Об этом скилле
PR Reviewer Skill
Conduct comprehensive, professional code reviews for GitHub Pull Requests using industry-standard criteria and automated tooling.
Table of Contents
- Purpose
- When to Use
- Review Process Workflow
- Reference Documentation
- Scripts Reference
- Best Practices
- Quick Reference Commands
- Tips for Effective Reviews
- Resources
Purpose
This skill performs code reviews by:
- Automating data collection - Fetching all PR-related information (metadata, diff, comments, commits, issues)
- Organizing review workspace - Creating structured directory with all artifacts
- Applying systematic criteria - Reviewing against comprehensive quality checklist
- Facilitating inline feedback - Optionally adding comments directly to PR code
- Ensuring completeness - Checking functionality, security, testing, maintainability
When to Use
Activate this skill when:
- A GitHub PR URL is provided with a review request
- Receiving "review this PR" or "code review" requests
- Checking PR quality before merging
- Providing systematic feedback on proposed changes
- GitHub PR review is mentioned in any context
Review Process Workflow
IMPORTANT: This skill uses a two-stage approval process. Nothing is posted to GitHub until explicit approval with /send or /send-decline.
Overview
- Fetch PR data - Collect all information
- Generate review files - Create detailed, human, and inline comment files
- Review and edit - Examine files, make changes as needed (use
/show) - Approve and post - Use
/send(approve) or/send-decline(request changes)
Step 1: Fetch PR Data
Use fetch_pr_data.py to automatically collect all PR information:
python scripts/fetch_pr_data.py <pr_url> [--output-dir <dir>] [--no-clone]
Actions performed:
- Parse PR URL to extract owner, repo, and PR number
- Create directory structure:
<output-dir>/PRs/<repo-name>/<PR-NUMBER>/ - Fetch PR metadata (title, author, state, branches, labels)
- Download PR diff and commit history
- Retrieve all PR comments and reviews
- Extract ticket references (JIRA, GitHub issues)
- Optionally clone source branch and generate git diff
Example:
python scripts/fetch_pr_data.py https://github.com/facebook/react/pull/28476
# Custom output directory
python scripts/fetch_pr_data.py https://github.com/owner/repo/pull/123 --output-dir /tmp/reviews
# Skip cloning (faster, no git diff)
python scripts/fetch_pr_data.py https://github.com/owner/repo/pull/123 --no-clone
Output structure:
/tmp/PRs/<repo-name>/<PR-NUMBER>/
├── metadata.json # PR metadata (title, author, branches)
├── diff.patch # PR diff from gh CLI
├── git_diff.patch # Git diff (if cloned)
├── comments.json # Review comments on code
├── commits.json # Commit history
├── related_issues.json # Linked GitHub issues
├── ticket_numbers.json # Extracted ticket references
├── SUMMARY.txt # Human-readable summary
└── source/ # Cloned repository (if not --no-clone)
Step 2: Analyze PR Data
After fetching, analyze collected data against review criteria:
- Read
SUMMARY.txt- High-level overview - Review
metadata.json- PR context, labels, assignees - Examine
diff.patch- Code changes - Check
comments.json- Existing feedback - Review
commits.json- Commit quality and messages - Check
related_issues.json- Linked tickets/issues - Apply review criteria - Evaluate against comprehensive checklist
Use the Read tool to examine files:
Read /tmp/PRs/<repo-name>/<PR-NUMBER>/SUMMARY.txt
Read /tmp/PRs/<repo-name>/<PR-NUMBER>/metadata.json
Read /tmp/PRs/<repo-name>/<PR-NUMBER>/diff.patch
Step 3: Generate Review Files
CRITICAL: After analysis, use generate_review_files.py to create structured review documents:
python scripts/generate_review_files.py <pr_review_dir> --findings <findings_json> [--metadata <metadata_json>]
Creates three files in pr_review_dir/pr/:
pr/review.md- Detailed internal review with emojis and line numberspr/human.md- Clean review for posting (no emojis, em-dashes, line numbers)pr/inline.md- Proposed inline comments with code snippets
Also creates slash commands in .claude/commands/:
/send- Post human.md and approve PR/send-decline- Post human.md and request changes/show- Open review directory in VS Code
Findings JSON structure:
{
"summary": "Overall assessment of the PR...",
"metadata": {
"repository": "owner/repo",
"number": 123,
"title": "PR title",
"author": "username",
"head_branch": "feature",
"base_branch": "main"
},
"blockers": [
{
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
- .gitignore
- .skilz-manifest.yaml
- README.md
- references/gh_cli_guide.md
- references/review_criteria.md
- references/scenarios.md
- references/troubleshooting.md
- scripts/add_inline_comment.py
- scripts/fetch_pr_data.py
- scripts/generate_review_files.py
FAQ
Что делает скилл pr-reviewer?
Comprehensive GitHub Pull Request code review skill. Use when asked to "review this PR", "code review", "review pull request", "check this PR", or when a GitHub PR URL is provided. Fetches PR metadata, diff, comments, commits, and related issues using gh CLI. Creates organized review workspace, analyzes code against industry-standard criteria, and optionally adds inline comments to the PR.
Как установить скилл pr-reviewer?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл pr-reviewer запускает скрипты?
Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.
Похожие скиллы
mcp-builder
AnthropicGuide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when…
claude-api
AnthropicReference for the Claude API / Anthropic SDK — model ids, pricing, params, streaming, tool use, MCP, agents, caching, token counting, model migration. TRIGGER…
algorithmic-art
AnthropicCreating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code…
mcp-integration
AnthropicThis skill should be used when the user asks to "add MCP server", "integrate MCP", "configure MCP in plugin", "use .mcp.json", "set up Model Context…