跳到主要内容
知仓学习社ZHICANG

code-review-guide

Review a pull request or diff like a thoughtful senior engineer — prioritized, kind, and focused on what matters. Use when reviewing code, giving PR…

不碰外部(只输出文字)无严重或高危命中mohitagw15856/pm-claude-skills

它会碰到什么

扫了多少1 个文本文件,3 KB
它会碰到什么不碰外部(只输出文字)
命中总数0 处
命中统计严重 0 · 高 0 · 中 0 · 低 0

这一栏是扫描器报的事实,不是结论。命中多不等于有毒(安全工具、规则库、示例脚本本来就会包含危险写法),命中少也不等于干净。它和你手上的凭据、文件、网络有什么关系,需要你自己看。

技能内容

Code Review Guide Skill

Bad code review nitpicks style while missing the design flaw, or dumps 40 ungraded comments. Good review is

prioritized and kind: it catches what actually matters (correctness, security, design), separates blocking

issues from nits, explains the why, and leaves the author better. This skill runs that review.

Required Inputs

Ask for these only if they aren't already provided:

  • The change — the diff/PR, and ideally its description/intent (what it's trying to do).
  • Context — language/stack, conventions, the part of the system it touches, risk level.
  • Focus (optional) — anything specific to scrutinize (security, performance, a tricky area).

Output Format

Review: [PR / change]

Summary — in 1–2 lines: what the change does and your overall read (solid / needs work / risky).

Review passes — scan in priority order and note findings:

  1. Correctness — does it do what it claims? Edge cases, error handling, off-by-ones, concurrency.
  2. Security & data — input validation, authz, secrets, injection, PII handling.
  3. Design — is this the right approach? Coupling, the seam, simpler alternative, future pain.
  4. Tests — do they cover the behavior and the edges? Would they catch a regression?
  5. Readability — names, clarity, dead code, docs where non-obvious.

Comments (ranked by severity) — each with file/line, the issue, why it matters, and a concrete suggestion:

| Severity | Where | Comment & why | Suggested change |

|---|---|---|---|

| 🔴 Blocking | | | |

| 🟡 Should-fix | | | |

| 🔵 Nit / optional | | | |

What's done well — genuinely (specific, not flattery). Reviews are also for morale and learning.

Verdict — ✅ Approve / 🔁 Request changes / 💬 Comment — with the one or two things that gate it.

Quality Checks

  • [ ] Correctness, security, and design are reviewed before style — priority order
  • [ ] Comments are ranked by severity (blocking vs. should-fix vs. nit), not a flat list
  • [ ] Each comment explains why and offers a concrete suggestion, not just "this is wrong"
  • [ ] At least one specific thing done well is noted
  • [ ] A clear verdict (approve / request changes) with the gating issues named
  • [ ] Tone is direct but kind — critiques the code, not the author

Anti-Patterns

  • [ ] Do not nitpick style while missing a correctness or security problem — priority first
  • [ ] Do not dump ungraded comments — rank them so the author knows what's blocking
  • [ ] Do not say "this is wrong" without why and a suggested fix
  • [ ] Do not rewrite it your way for taste — respect working approaches; flag real issues
  • [ ] Do not be a jerk — review the code, acknowledge good work, keep the author motivated

Based On

Senior code-review practice (Google's engineering review guidelines): prioritize correctness/design, severity-tag feedback, be kind.

想直接用这个技能?

本站把开放许可(MIT / Apache 等)的技能按仓库打包整理到网盘,点一下转存到你自己的网盘,不用一个个从 GitHub 拉。许可未声明的技能只给原始仓库链接,不打包。

同名技能的其他版本

有 3 个不同仓库或目录里都有叫 code-review-guide 的技能。它们内容并不相同,别混用: