← ClaudeAtlas

pr-devlisted

Manage PR lifecycle — fetch fresh PR state, address every unresolved review thread, fix CI, get user approval, then squash-merge and clean up. Use when the user wants to drive a PR through review and merge.
Tamircohen28/tamirs-superpowers · ★ 0 · Code & Development · score 76
Install: claude install-skill Tamircohen28/tamirs-superpowers
## Live context !`gh pr view --json number,title,state,headRefName,reviewDecision,mergeable 2>/dev/null | jq -r '"PR #\(.number): \(.title) [\(.state)] branch:\(.headRefName) reviews:\(.reviewDecision) mergeable:\(.mergeable)"' 2>/dev/null || echo "no open PR on current branch — provide a PR number"` !`git branch --show-current 2>/dev/null | sed 's/^/current branch: /' || true` # pr-dev Drive a pull request through review and merge: address every unresolved thread, fix CI, validate readiness, then (after explicit user approval) squash-merge and clean up. ## Input Parse `$ARGUMENTS` as the PR number. If empty, detect from current branch: ```bash gh pr view --json number --jq .number ``` If no PR found, ask for the PR number and stop. ## Required execution flow ### 1. Fetch fresh PR state **Never rely on cached state.** Always re-fetch live: ```bash PR_NUMBER=<number> REPO=$(gh repo view --json nameWithOwner --jq .nameWithOwner) OWNER=${REPO%/*} REPO_NAME=${REPO#*/} gh pr view $PR_NUMBER --json title,state,headRefName,baseRefName,body,mergeable gh pr checks $PR_NUMBER # Fetch unresolved review threads via GraphQL gh api graphql -f query=' query($owner: String!, $repo: String!, $number: Int!) { repository(owner: $owner, name: $repo) { pullRequest(number: $number) { reviewThreads(first: 50) { nodes { id isResolved comments(first: 1) { nodes { body author { login } } } }