ia-code-reviewlisted
Install: claude install-skill iliaal/whetstone
# Code Review
## Two-Stage Review
**Stage 1 -- Spec compliance** (do this FIRST): verify the changes implement what was intended. Check against the PR description, issue, or task spec. Identify missing requirements, unnecessary additions, and interpretation gaps. If the implementation is wrong, stop here -- reviewing code quality on the wrong feature wastes effort.
**Stage 2 -- Code quality**: only after Stage 1 passes, review for correctness, maintainability, security, and performance.
## Scope Resolution
**Pre-flight**: verify `git rev-parse --git-dir` exists before anything else. If not in a git repo, ask for explicit file paths.
When no specific files are given, resolve scope via this fallback chain:
1. User-specified files/directories (explicit request)
2. Session-modified files (`git diff --name-only` for unstaged + staged)
3. All uncommitted files (`git diff --name-only HEAD`)
4. Untracked files (`git ls-files --others --exclude-standard`) -- new files are often most review-worthy
5. **Zero files → stop.** Ask what to review.
Exclude: lockfiles, minified/bundled output, vendored/generated code.
### Base-branch resolution for branch reviews
When the review target is a branch (not a working-tree diff), the comparison range is the **merge-base**, not the working-tree delta — resolve it before reading any diff. Full fallback chain (PR base → default-branch inference → `origin/*` fallback list → `git merge-base` → shallow-clone retry) and the "never fall back to `g