Pr review fix
Use when a PR is open and needs review (including the shorthand "fixpr"). Fetches PR state, reviews the diff, fixes issues directly in the worktree, pushes, and comments on the PR about what was fixed. Can loop until clean.From its SKILL.md
npx -y skills add ANaka/work-cycle --skill pr-review-fixAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
2 things to look at
- no licenseNo license file was found in the repository. Code published without one is not open source by default, so using it at work is a question for whoever answers licensing questions where you are.
- 0 stars0 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
SKILL.md
4.8 KB, as published. Nobody here has run it
PR Review Fix
Review an open PR, fix issues directly, push, and comment. Default behavior is fix-and-document, not report-and-wait.
Terminology
Uses the same definitions as plan-do-review-renew:
sync — sync local repo main to remote main (git checkout main && git pull). If continuing in a worktree, also sync the worktree's local main reference.
mergesync — merge the PR (gh pr merge --merge --delete-branch), then sync. One atomic operation.
fixpr — shorthand for this workflow. Treat user phrases like fixpr, fix PR, review-fix-comment, "fix this PR and comment", or "review this PR, push fixes, and leave comments" as invocations of this skill. Default mode is fix, not comment-only — switch to comment-only only when the user explicitly says "just review", "comment only", "don't push", or no safe worktree/branch is available.
check — fetch ALL PR state:
gh pr view <number>
gh api repos/{owner}/{repo}/pulls/{number}/reviews
gh api repos/{owner}/{repo}/pulls/{number}/comments
gh pr view <number> --json commits
gh pr checks <number>
Step 1 — Locate PR and Worktree
Accept PR number, URL, or infer from current branch. Then:
- Run check to fetch full PR state
- Extract the worktree path from the PR body (plan-do-review-renew puts
Worktree: <path>in PR descriptions) - If no worktree path in PR body, check
git worktree listfor a worktree on the PR's head branch - If no worktree found, fall back to comment-only mode (skip Step 3, go straight to Step 4 after review)
Confirm before proceeding:
Reviewing PR #
<number>:<title>Worktree:<path>| Branch:<branch>| Mode: fix (or comment-only if no worktree)
User can also explicitly request comment-only mode (e.g. "just review", "comment only", "don't fix").
Step 2 — Review
Read the full diff against the PR's base branch:
Fix mode:
cd <worktree-path>
git diff <base-branch>...HEAD
Comment-only mode (no worktree):
gh pr diff <number>
Review for:
- Logic errors and bugs
- Security issues (injection, auth, data exposure)
- Test gaps — new code paths without test coverage
- Project conventions (check package-level
CLAUDE.mdfor patterns) - Performance issues (unnecessary allocations, N+1 queries, missing indexes)
Classify each finding by severity:
| Severity | Meaning | Action |
|---|---|---|
| Critical | Broken logic, security vulnerability, data loss risk | Must fix |
| Important | Correctness issue, missing edge case, test gap | Fix by default |
| Minor | Style, naming, minor simplification | Fix if trivial, otherwise note |
| Observation | Not wrong, but worth knowing | Comment only, do not fix |
If in comment-only mode, skip to Step 4. After posting the comment, the review is done — do not proceed to Step 5.
Otherwise, proceed to Step 3 (fix is the default when a worktree is available).
Step 3 — Fix
For each Critical and Important finding (and trivial Minor findings):
- Make the fix in the worktree
- Run relevant tests to confirm the fix doesn't break anything
- Track what was fixed (for the PR comment in Step 4)
If a fix is non-trivial or ambiguous, ask the user before applying it.
After all fixes:
cd <worktree-path>
git add <fixed-files>
git commit -m "review: fix <concise summary>"
git push
Step 4 — Comment on PR
Post a single review comment summarizing all findings and fixes:
gh pr comment <number> --body-file /tmp/review-comment.md
Comment structure:
## Review Summary
### Fixed
- [Critical] <description> — fixed in <commit-sha-short>
- [Important] <description> — fixed in <commit-sha-short>
- [Minor] <description> — fixed in <commit-sha-short>
### Not Fixed (needs discussion)
- [Minor] <description> — <reason skipped>
### Observations
- <observation>
Use --body-file to avoid shell quoting issues with markdown.
Comment-only mode ends here. Do not proceed to Step 5.
Step 5 — Re-review (fix mode only)
After pushing fixes, re-read the diff to check:
- Did any fix introduce a new issue?
- Are there remaining findings that were deferred?
If clean (no new issues, no deferred Critical/Important findings), present options:
mergesync— merge the PR now, sync (only offer when invoked standalone, not from within plan-do-review-renew)done— leave PR open, report what was doneanother-pass— run Steps 2–5 again (e.g. if fixes were complex)
If new issues found, loop back to Step 3 automatically (max 3 cycles, then present findings to user).