Fix issues from PR review manifest
Fixes issues from PR review manifest by applying automated fixes and updating tracking files.
/plugin marketplace add cameronsjo/claude-marketplace/plugin install essentials@cameronsjo<pr_number>.claude/reviews/pr-$ARGUMENTS.yamlbranch field in manifest)BLOCKER → MAJOR → MINOR (skip NIT)fixed in manifest# Verify we can push to this branch
git status
git remote -v
# Check we're on the right branch
git branch --show-current
If not on the correct branch or can't push, STOP and report.
Within each severity, batch by file to minimize read/write cycles.
For each file with findings:
1. Read file once, note all finding locations
2. Apply fixes from bottom-to-top (preserves line numbers)
3. Verify fixes don't conflict with each other
4. Write file once
5. Update manifest for all findings in that file
Update the manifest:
findings:
- id: 1
# ... other fields ...
status: fixed
fixed_at: 2025-01-15T11:00:00Z
commit: abc1234
Commit fixes with references to finding IDs:
git commit -m "fix(scope): description [PR-{number}#{finding_id}]"
Group related fixes into logical commits by file or feature.
After committing, handle the PR:
# Check if PR exists for this branch
gh pr list --head $(git branch --show-current) --json number,url
# If PR exists: push updates
git push
# If no PR exists: create one
gh pr create --title "Fix review findings from PR #$ARGUMENTS" \
--body "Addresses findings from review manifest."
After fixing each finding, resolve the corresponding inline PR comment:
# Get review comments on the PR
gh api repos/{owner}/{repo}/pulls/$ARGUMENTS/comments --jq '.[] | {id, path, line, body}'
# Find comments matching the finding's file:line
# Reply to the comment indicating it's fixed
gh api repos/{owner}/{repo}/pulls/$ARGUMENTS/comments/{comment_id}/replies \
-f body="Fixed in \`{commit_sha}\`"
If the fix was part of a review thread, mark the conversation as resolved:
# Get the thread ID from the comment
gh api graphql -f query='
mutation {
resolveReviewThread(input: {threadId: "{thread_id}"}) {
thread { isResolved }
}
}
'
After fixes are pushed, suggest running /pr-review $ARGUMENTS again to verify:
Summarize: