Address reviews
Handle code reviews from .review files created during local review sessions.
When to use
- •User mentions "reviews", "fix reviews", "address review comments"
- •You see
.reviewfiles in the repository - •User asks you to check for review feedback
Finding review files
bash
find . -name "*.review" -type f 2>/dev/null
Review file format
Review files are named <source-file>.review and placed next to the source file:
- •
src/auth.ts→src/auth.ts.review - •
lib/utils.py→lib/utils.py.review
Structure
markdown
# Review: filename.ts **Status:** request-changes | approved | in-progress ## L42 | must-fix Comment text explaining what needs to be fixed. ## L15-18 | suggestion Consider this alternative approach. ## L88 | question Why is this implemented this way? ## L5 | nit Minor style issue. ## L100 | praise Nice solution here!
Comment types (priority order)
- •must-fix - Blocking issues, fix before proceeding
- •question - Need clarification from reviewer, ask before proceeding
- •suggestion - Consider implementing, use judgment
- •nit - Minor issues, fix if easy
- •praise - No action needed, acknowledgment
Workflow
- •
Find all reviews:
bashfind . -name "*.review" -type f
- •
Read each review file to understand feedback
- •
Process by priority:
- •Address all
must-fixitems first - •For
questionitems: If you can't determine the answer from context, ask the user - •Apply
suggestionitems if they make sense - •Fix
nititems if straightforward
- •Address all
- •
After fixing each file:
- •Delete the
.reviewfile (it's served its purpose) - •Or if questions remain, leave the file but note which items are resolved
- •Delete the
Handling questions
When you encounter a question type comment:
- •
Try to understand the intent from code context
- •
If unclear, ask the user directly:
codeReview question at src/auth.ts:88: "Why is this timeout 30s?" Should I: (a) keep as is, (b) reduce it, (c) make it configurable?
After addressing reviews
Once all reviews are addressed:
bash
# Verify no reviews remain find . -name "*.review" -type f
If empty, reviews are complete. Otherwise, report remaining items.
Example response
When asked to "fix the reviews":
code
Found 2 review files: - src/auth.ts.review (2 must-fix, 1 suggestion) - src/utils.ts.review (1 question) Addressing src/auth.ts: - L42 must-fix: Added null check ✓ - L67 must-fix: Fixed error handling ✓ - L15 suggestion: Refactored to use Map ✓ For src/utils.ts: - L88 question: "Why cache for 1 hour?" → Need your input: Should I (a) keep 1 hour, (b) reduce to 15 min, (c) make configurable?