reviewing-code — Claude Code skill: step-by-step code review
A skill that walks your code through a checklist: correctness, maintainability, performance, types and tests. Useful when a change needs review before merge.
npx skills add spencerpauly/awesome-cursor-skills --skill reviewing-code -a claude-codeWhat reviewing-code does
The skill kicks in when you ask for a code review or feedback on your code. It reads the files or the diff first and works out the scope: new feature, bug fix or refactor. Then it goes down the list.
Correctness covers empty input, null, zero and negative numbers, error states via try/catch and fallback UI, race conditions and timeouts in async code, off-by-one errors in loops. Maintainability looks at single-responsibility functions, descriptive names, duplication worth extracting, magic numbers, deep nesting. Performance checks for N+1 query patterns, expensive work inside render loops, large lists without virtualization or pagination, missing indexes for common queries. On TypeScript projects it also flags any types, missing return types on public APIs and non-exhaustive union handling.
Findings come sorted into three buckets: must fix (bugs, security, data loss), should fix (performance, maintainability) and nit (style). Each one lists the file, the line, the issue and a suggested fix. The skill asks the agent to explain why something is a problem and to call out what was done well. Style points a linter or formatter already handles are left alone.
What it helps with
- review a diff before merge and catch bugs
- check how empty input and null are handled
- spot N+1 query patterns in database access
- narrow
anytypes in a TypeScript codebase - see whether tests cover error cases, not just the happy path
Example prompts for the agent
- review this diff
- check
src/api/orders.tsfor correctness and performance - look at the branch changes and sort findings by severity
How to install reviewing-code
1Skills CLI (Vercel)
npx skills add spencerpauly/awesome-cursor-skills --skill reviewing-code -a claude-code2Manually: put the files in place
~/.claude/skills/reviewing-code/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/reviewing-code/
1Skills CLI (Vercel)
npx skills add spencerpauly/awesome-cursor-skills --skill reviewing-code -a codex2Manually: put the files in place
.agents/skills/reviewing-code/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add spencerpauly/awesome-cursor-skills --skill reviewing-code -a cursor2Manually: put the files in place
.cursor/skills/reviewing-code/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install spencerpauly/awesome-cursor-skills reviewing-code2Manually: put the files in place
.github/skills/reviewing-code/SKILL.md1Skills CLI (Vercel)
npx skills add spencerpauly/awesome-cursor-skills --skill reviewing-code -a gemini-cli2Platform CLI
gemini skills install https://github.com/spencerpauly/awesome-cursor-skills --path resources/reviewing-codeManually: put the files in place
.devin/skills/reviewing-code/SKILL.mdThe legacy .windsurf/skills/ path still works
Skills CLI (Vercel)
npx skills add spencerpauly/awesome-cursor-skills --skill reviewing-code -a opencodeClaude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
Step by step, with commands for each platform: How to install skills in Claude Code: five ways
Questions about reviewing-code
How do I install reviewing-code in Claude?
Run npx skills add spencerpauly/awesome-cursor-skills --skill reviewing-code -a claude-code. The skill lands in ~/.claude/skills/reviewing-code/SKILL.md.
What does reviewing-code do?
It runs code through a checklist: correctness, maintainability, performance, types and tests. You get findings with the file, line and a suggested fix.
Which platforms support the skill?
Claude, Codex, Cursor, GitHub Copilot, Gemini CLI and OpenCode. Each platform has its own install command.
Source text
SKILL.md · CC0-1.0
--- name: reviewing-code description: Perform a thorough code review focused on correctness, maintainability, performance, and best practices. --- # Code Review Use this skill when the user asks for a code review, feedback on their code, or to check code quality. ## Steps 1. **Understand the change** — read the files or diff to understand what the code is supposed to do. Identify the scope (new feature, bug fix, refactor). 2. **Check correctness** - Does the code handle edge cases (empty input, null, zero, negative numbers)? - Are error states handled (try/catch, error boundaries, fallback UI)? - Does async code handle race conditions, cancellation, and timeouts? - Are there off-by-one errors in loops or array access? 3. **Check maintainability** - Are functions focused on a single responsibility? - Are variable and function names descriptive? - Is there unnecessary duplication that should be extracted? - Are magic numbers replaced with named constants? - Is the code complexity reasonable (deeply nested conditionals, long functions)? 4. **Check performance** - Are there N+1 query patterns in database access? - Are expensive computations or API calls happening in render loops? - Are large lists missing virtualization or pagination? - Are there missing indexes for common database queries? - Is memoization used appropriately (not over-applied)? 5. **Check type safety** (TypeScript projects) - Are there `any` types that should be narrowed? - Are function return types explicit for public APIs? - Are union types handled exhaustively? 6. **Check testing** - Are there tests for the new/changed code? - Do tests cover the happy path AND error cases? - Are tests isolated (no shared mutable state)? 7. **Provide feedback** — organize findings by severity: - **Must fix**: bugs, security issues, data loss risks - **Should fix**: performance issues, maintainability concerns - **Nit**: style preferences, minor suggestions For each finding, include the file, line, the issue, and a suggested fix. ## Notes - Be constructive — explain *why* something is a problem, not just that it is. - Acknowledge what's done well, not just what needs fixing. - Don't bikeshed on style issues that a linter/formatter should handle.
© spencerpauly · CC0-1.0 · spencerpauly/awesome-cursor-skills