Token导航 LogoToken导航TokenDH.com
研究检索需要联网github未标认证来源可访问clear审计通过

code-review代码审查

Agent Skill

code-review 用于查找、检索和筛选相关信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

259

周安装

11

GitHub Stars

1

下载量

91
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

3

许可证

MIT

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:code-review(代码审查)
来源仓库:https://github.com/sebastiaanwouters/dotagents
仓库路径:skills/code-review
安装命令:
npx skills add https://github.com/sebastiaanwouters/dotagents --skill code-review
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。不同来源提供的安装方式可能略有差异;本站展示可直接复制的安装命令,安装前请核对来源页面。

skills.shnpx skills
npx skills add https://github.com/sebastiaanwouters/dotagents --skill code-review

简介

code-review 用于查找、检索和筛选相关信息。

  • 适合在 Codex、Claude、Cursor、Gemini CLI 中根据关键词快速定位候选结果。
  • 通过 npx skills add 命令从指定仓库安装并使用该技能。
  • 安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。
  • 可结合来源仓库和原始 README 进一步核验具体用法和功能边界。

SKILL.md

Code Review Skill

Reviews code through battle-tested engineering principles with comprehensive quality gates.

Usage

Tell me what to review:

  • "Review src/auth.ts"
  • "Review the changes in git diff HEAD~3"
  • "Review this PR for merge readiness"

Review Process

  1. Read the code — Understand what it does
  2. Verify functionality — Check for bugs, edge cases, correctness
  3. Assess test coverage — Ensure changed code has adequate tests
  4. Evaluate test quality — Check tests follow best practices (not flaky)
  5. Check guideline compliance — Verify AGENTS.md/CLAUDE.md adherence
  6. Apply philosophy lenses — Check against engineering principles
  7. Run QA checks — Execute lint, typecheck, tests (after fixes)
  8. Output structured findings — Categorized, actionable feedback

1. Functionality Verification

Correctness Checklist

  • Does the code do what it's supposed to do?
  • Are all requirements/acceptance criteria met?
  • Are edge cases handled? (null, empty, boundary values, overflow)
  • Are error conditions handled gracefully?
  • Is the happy path tested AND working?
  • Are race conditions possible? (async, concurrent access)
  • Is state managed correctly? (no stale data, proper initialization)

Bug Detection Signals

SignalQuestion
Off-by-oneLoop bounds, array indices, comparisons (< vs <=)
Null/undefinedCan any value be null when accessed?
Type coercionImplicit conversions causing bugs? (JS: "5" + 3)
Resource leaksFiles, connections, memory properly closed?
Infinite loopsCan loop conditions fail to terminate?
Integer overflowLarge numbers handled safely?
Security holesSQL injection, XSS, path traversal, secrets exposed?

2. Test Coverage Assessment

Coverage Requirements

  • New code: Must have tests covering primary functionality
  • Bug fixes: Must have regression test proving fix
  • Changed code: Tests should cover modified behavior
  • Critical paths: Auth, payments, data mutations require high coverage

Coverage Analysis

Is the changed code tested? → NO → Block: Add tests
     ↓ YES
Are edge cases covered? → NO → Request edge case tests
     ↓ YES
Are error paths tested? → NO → Request error handling tests
     ↓ YES
Coverage adequate ✓

Google's Coverage Guidelines

  • 60%: Acceptable minimum
  • 75%: Commendable
  • 90%: Exemplary
  • Per-commit: 90%+ for changed lines is reasonable
Focus on what's NOT covered rather than hitting arbitrary numbers.

3. Test Quality (Non-Flaky Tests)

FIRST Principles for Good Tests

PrincipleMeaning
FastRun quickly (milliseconds for unit tests)
IsolatedNo dependencies on other tests or external state
RepeatableSame result every time, any environment
Self-validatingPass or fail, no manual interpretation
TimelyWritten close to the code (ideally before - TDD)

Flaky Test Detection

Tests are flaky if they fail intermittently without code changes.

Common Causes:

  • Time/date dependencies (use fixed/mocked time)
  • Random data without seed control
  • Shared mutable state between tests
  • Network/external service calls
  • Race conditions in async code
  • File system dependencies
  • Database state leakage
  • Order-dependent tests

Test Quality Checklist

  • Tests are deterministic (same input → same output)
  • Tests clean up after themselves (no side effects)
  • Tests don't depend on execution order
  • Async operations properly awaited
  • External dependencies mocked/stubbed
  • Time-sensitive tests use controlled time
  • Random values use seeded generators
  • Tests have meaningful assertions (not just expect(true))
  • Test names describe behavior being tested
  • One logical assertion per test

Red Flags in Tests

  • sleep() or arbitrary delays
  • Commented-out assertions
  • Empty catch blocks swallowing failures
  • Tests that pass when logic is deleted (useless tests)
  • expect(result).toBeDefined() without checking value
  • Shared state between it() blocks
  • Network calls without mocking

4. QA Checks

Before Approving, Verify:

  1. Lint passes: npm run lint, eslint, etc.
  2. Types check: tsc --noEmit, npm run typecheck, etc.
  3. Tests pass: npm test, pytest, etc.
  4. Build succeeds: npm run build, cargo build, etc.

Automated QA Flow

Run lint → FAIL → Must fix before merge
    ↓ PASS
Run typecheck → FAIL → Must fix before merge
    ↓ PASS
Run tests → FAIL → Must fix (unless pre-existing)
    ↓ PASS
Build → FAIL → Must fix before merge
    ↓ PASS
QA Passed ✓

5. Guidelines Compliance

AGENTS.md / CLAUDE.md Adherence

Check if the codebase has guidance files:

  • AGENTS.md or CLAUDE.md in root or relevant directories
  • Project-specific coding standards
  • Architecture decisions and patterns

Compliance Checklist

  • Follows documented code style
  • Uses approved libraries/patterns
  • Adheres to naming conventions
  • Follows directory structure guidelines
  • Respects forbidden patterns (if documented)
  • Matches documented architectural decisions

6. Engineering Philosophy Lenses

Grug Brain Check (Complexity Demon Detection)

  • Is this the simplest solution?
  • Could a newcomer understand it in 30 seconds?
  • Are there unnecessary abstractions?

Code Smell Detection

SmellQuestion
Long Method>50 lines? One sentence description?
Long Params>3 parameters? Group them?
Feature EnvyUses another class more than its own?
Shotgun SurgeryOne change = many file edits?
Dead CodeUnreachable or unused?

Unix Philosophy Check

  • Does each function do ONE thing well?
  • Can components be tested in isolation?
  • Are there side effects in "pure" functions?

DRY/KISS

  • Is logic duplicated?
  • Is there a simpler solution?

Output Format

## Summary
[One-line verdict: APPROVE / NEEDS WORK / RETHINK]

## QA Status
- Lint: ✓/✗
- Typecheck: ✓/✗
- Tests: ✓/✗ (X passed, Y failed)
- Build: ✓/✗

## Functionality Issues
[Bugs, incorrect behavior, edge cases]

## Test Coverage Gaps
[Untested code paths, missing tests]

## Test Quality Issues
[Flaky tests, bad patterns]

## Guidelines Violations
[AGENTS.md/CLAUDE.md non-compliance]

## Code Quality
[Design issues, maintainability]

## Nitpicks
[Minor suggestions]

## What's Good
[Acknowledge solid work]

Severity Levels

LevelMeaningAction
🔴 CriticalBugs, security, data loss, broken testsBlock merge
🟠 ImportantMissing tests, design issuesShould fix
🟡 SuggestionCould be betterConsider
🟢 NitpickStyle, minor preferenceOptional

Master Decision Tree

Does it work correctly? → NO → 🔴 Fix bugs first
     ↓ YES
Does it have tests? → NO → 🔴 Add tests
     ↓ YES
Are tests good (not flaky)? → NO → 🟠 Fix test quality
     ↓ YES
Does QA pass? → NO → 🔴 Fix QA failures
     ↓ YES
Follows guidelines? → NO → 🟠 Align with standards
     ↓ YES
Is it simple? → NO → 🟡 Consider simplifying
     ↓ YES
APPROVE ✓

What NOT to Do

  • Don't nitpick formatting (use formatters)
  • Don't demand unnecessary abstractions
  • Don't block on style preferences
  • Don't rewrite working code for elegance alone
  • Don't ignore test failures as "probably flaky"

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

04

需要参考平台分布和安装热度时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

补充不同宿主或平台的使用分布数据

能力 5

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Claude Code

26.71%
按下载量换算24

windsurf

24.95%
按下载量换算23

amp

18.01%
按下载量换算16

trae

11.34%
按下载量换算10

OpenCode

8.56%
按下载量换算8

Codex

3.7%
按下载量换算3

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

需要联网

该 Skill 可能需要联网访问来源站点、仓库或外部 API;具体网络访问范围需要结合源码和 README 复核。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。

来源信息

继续浏览同类 Skills