LLM Skills
~/catalog/debugging & maintenance//05_resolve_pr_comments

PR Comment Resolution System Invite

/05_resolve_pr_comments

Claude Code automatically understands the context of the Git branch and the current PR. You don't need to specify which PR you're working on

EveryIncEveryInc
533
November 24, 2025
// skill content

Claude Code PR Comment Resolution System Prompt You are using Claude Code to systematically resolve all comments, to-dos, and issues in a pull request. Claude Code operates directly in your terminal, understands context, maintains awareness of your entire project structure, and takes action by performing real operations like editing files and creating commits. ## Context Awareness Claude Code automatically understands the current git branch and PR context. You don't need to specify which PR you're working on - Claude Code will: - Detect the current branch - Understand associated PR context - See all PR comments and review threads automatically ## Workflow Approach Follow the research/plan/implement pattern that significantly improves performance for problems requiring deeper thinking: ### Phase 1: Research & Analysis `` Please analyze this PR and all its comments comprehensively. Look for: 1. All unresolved review comments and conversations 2. To-do items mentioned in comments 3. Requested changes from code reviews 4. Questions that need responses Use the GitHub API systematically to get complete data about all comment types. ` ### Phase 2: Planning ` Based on your analysis, create a detailed plan to address all unresolved items. Group them by type (code changes, documentation, responses to questions). Prioritize based on importance and dependencies. Use TodoWrite tool to track progress systematically. ` ### Phase 3: Implementation ` Now implement the solutions for each item in the plan: - Make the requested code changes - Update documentation as needed - Prepare responses to questions - Ensure all changes maintain code quality and pass tests - Mark each todo as completed when finished ` ### Phase 4: Resolution & Verification ` After addressing all items: 1. Run linting and tests to verify everything works 2. Create a summary of all changes made 3. Commit the changes with a clear message 4. Verify all review comments have been addressed ` ## Correct GitHub API Commands for Comment Retrieval The key is to use the right API endpoints that actually work. Here are the tested, working commands: ### 1. Get Current PR Number and Basic Info `bash # Get current PR details gh pr status # View PR with all comments (readable format) gh pr view --comments ` ### 2. Get All Review Comments (Code-Level Comments) `bash # Get review comments (comments on specific lines of code) gh api repos/{owner}/{repo}/pulls/{pr_number}/comments | jq '.[] | {id: .id, author: .author.login, body: .body, created_at: .created_at, in_reply_to_id: .in_reply_to_id}' # For current repo, use variables: gh api repos/$(gh repo view --json owner,name | jq -r '.owner.login')/$(gh repo view --json owner,name | jq -r '.name')/pulls/$(gh pr view --json number | jq -r '.number')/comments ` ### 3. Get All Review Summaries `bash # Get review summaries (approve/request changes/comment) gh api repos/{owner}/{repo}/pulls/{pr_number}/reviews | jq '.[] | select(.state == "COMMENTED") | {id: .id, author: .author.login, body: .body, submitted_at: .submitted_at}' ` ### 4. Get Issue Comments (General PR Comments) `bash # Get general PR discussion comments gh pr view --json comments | jq '.comments[] | {id: .id, author: .author.login, body: .body, created_at: .created_at}' ` ### 5. Filter for Unresolved Comments Based on Content Analysis Since GitHub doesn't have a "resolved" status for individual comments, you need to analyze content: `bash # Look for comments that indicate unresolved issues gh api repos/{owner}/{repo}/pulls/{pr_number}/comments | jq '.[] | select(.body | test("(todo|TODO|FIXME|suggestion|issue|problem|fix|change|update|add|remove|modify)"; "i")) | {id: .id, body: .body, author: .author.login}' ` ### 6. Advanced: Check for Comments Without Follow-up Responses `bash # Get all comments and check which ones don't have replies gh api repos/{owner}/{repo}/pulls/{pr_number}/comments | jq 'group_by(.in_reply_to_id // .id) | map(select(length == 1 and .[0].in_reply_to_id == null)) | flatten | .[] | {id: .id, body: .body, needs_response: true}' ` ## Practical Comment Resolution Workflow ### Step 1: Comprehensive Comment Discovery `bash # Run all these in parallel for complete picture: gh pr view --comments # Human-readable overview gh api repos/$(gh repo view --json owner,name | jq -r '.owner.login')/$(gh repo view --json owner,name | jq -r '.name')/pulls/$(gh pr view --json number | jq -r '.number')/comments | jq '.[] | {id: .id, author: .author.login, body: .body, created_at: .created_at, in_reply_to_id: .in_reply_to_id}' gh api repos/$(gh repo view --json owner,name | jq -r '.owner.login')/$(gh repo view --json owner,name | jq -r '.name')/pulls/$(gh pr view --json number | jq -r '.number')/reviews | jq '.[] | select(.state == "COMMENTED") | {id: .id, author: .author.login, body: .body, submitted_at: .submitted_at}' ` ### Step 2: Intelligent Comment Classification ``bash # C

// original public source
EveryInc/claude_commands
/05_resolve_pr_comments.md
License: License not specified. Review the repository before reusing it.
Independent project, not affiliated with Anthropic. This skill remains the property of its original author.
// install this skill
Paste this command in your terminal at the root of your project:
mkdir -p .claude/commands && curl -o ".claude/commands/05_resolve_pr_comments.md" "https://raw.githubusercontent.com/EveryInc/claude_commands/main/05_resolve_pr_comments.md"
Then in Claude Code, type /05_resolve_pr_comments to activate it.
open_in_newOpen original source
// save
Save available after sign in.
loginSign in to save
// information
CreatorEveryInc
Stars 533
UpdatedNovember 24, 2025
Format.md
AccessFree
// similar

Skills Debugging & maintenance

View allarrow_forward