review-pr

GitHub

用于审查GitHub Pull Request的技能。通过命令行工具获取PR详情、差异及CI状态,在独立工作区中比对代码,依据标准生成带严重等级的逐行评论与整体评估,仅输出结果不修改仓库。

.claude/skills/review-pr/SKILL.md music-assistant/server

Trigger Scenarios

用户请求审查Pull Request 分享PR链接 输入/review-pr命令

Install

npx skills add music-assistant/server --skill review-pr -g -y
More Options

Non-standard path

npx skills add https://github.com/music-assistant/server/tree/dev/.claude/skills/review-pr -g -y

Use without installing

npx skills use music-assistant/server@review-pr

指定 Agent (Claude Code)

npx skills add music-assistant/server --skill review-pr -a claude-code -g -y

安装 repo 全部 skill

npx skills add music-assistant/server --all -g -y

预览 repo 内 skill

npx skills add music-assistant/server --list

SKILL.md

Frontmatter
{
    "name": "review-pr",
    "description": "Use when asked to review a GitHub pull request, PR link is shared, or user says \/review-pr"
}

Review GitHub Pull Request

Review the GitHub pull request: $ARGUMENTS.

This is a read-only review. Report findings in the console — never post comments, approve, or request changes on GitHub, and never modify the code under review.

Steps

  1. gh pr view for the PR details and description.
  2. Create a git worktree and do everything below inside it, so the reviewer's checked-out branch stays untouched (git worktree add --detach <path>).
  3. gh pr checkout in the worktree, then confirm the local commit hash matches the remote PR head.
    • HARD STOP: if the checkout fails, or the hashes still differ afterwards, stop and report it. No workarounds — not git fetch, not reviewing from the diff alone. Wait for instructions.
  4. gh pr checks for CI status.
  5. gh pr diff for the changes, then read the surrounding code for anything the diff alone can't settle.
  6. Apply REVIEW_STANDARDS.md, in the same directory as this skill.

Running tests or linters isn't part of this — CI does that.

Output Format

Comments per file and line that need attention. Skip what's already fine.

Each comment carries a severity ([CRITICAL], [PROBLEM], [SUGGESTION]), states the problem in a sentence, says why it matters when that isn't self-evident, and gives a concrete fix or snippet.

Close with an overall assessment — approve, request changes, or comment — followed by the findings grouped by severity.

Version History

  • f6f4107 Current 2026-07-31 07:15

    对齐上下文工程指南:移除低价值禁令列表,改为解释原因;引用外部配置文件而非内联过时命令;增加关联Issue验证;调整步骤顺序以优先创建worktree;删除示例输出以避免引导偏差。

  • f671dd0 2026-07-05 15:01

Metadata

Files
0
Version
5ac354a
Hash
16606e86
Indexed
2026-07-05 15:01

Главная - Вики-сайт
Copyright © 2011-2026 iteam. Current version is 2.155.2. UTC+08:00, 2026-08-07 01:54
浙ICP备14020137号-1 $Гость$