From github-pr-comment-resolution
Help resolve GitHub pull request review comments using the GitHub CLI (`gh`). Use when the user asks to address, resolve, or summarize PR comments, update code accordingly, and optionally draft or post replies back to GitHub.
How this skill is triggered — by the user, by Claude, or both
Slash command
/github-pr-comment-resolution:github-pr-comment-resolutionThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
When helping with GitHub pull request (PR) comments, follow this workflow:
When helping with GitHub pull request (PR) comments, follow this workflow:
Identify the PR
gh pr list --head $(git rev-parse --abbrev-ref HEAD) --json number,title,headRefName,state --limit 5 in the repo root to find the open PR for the current branch, and use that PR. Do not ask the user which PR to work on unless this lookup returns no PR or the result is ambiguous (e.g. multiple PRs for the same branch).Inspect PR and comments via gh CLI
gh command-line tool to interact with GitHub.gh is authenticated for the correct GitHub account and has access to the repository.gh commands to:
gh pr view <number> --json ....gh pr view <number> --comments or gh api calls to the relevant review/comment endpoints.Organize comments
Resolve comments iteratively
ApplyPatch in Cursor).Validate changes locally
Draft replies and mark resolution
gh commands to help manage reviews and comments when appropriate. Examples:
gh pr comment <number> --body "<reply>" to post a comment on the PR.gh api calls to review/comment endpoints when you need finer-grained control (for example, posting inline replies tied to specific review comments or creating a review with multiple comments).gh api calls.When reviewing each PR comment, classify it into one of these categories and respond accordingly:
Blocking / must-fix:
Strong suggestion:
Nit / style:
Questions / clarifications:
Use these templates when drafting replies to PR comments (adapt tone to match the repository's existing reviews):
Change implemented
[...] and added [...] to cover the edge case."[...] into [...] for clarity and to avoid the duplicated logic."Clarification with code change
[...] and added [...] so the intent is clearer."Clarification without code change
[...] here is [...]. Given [...], I'd prefer to keep the current behavior, but I'm open to adjusting if you'd like."Deferring non-critical suggestions
gh CLI SafelyWhen interacting with GitHub via the gh CLI:
gh commands to the target PR and repository the user is working on (for example, gh pr view <number>).--json flags) when you need structured data for analysis.gh pr view, gh pr list, and related commands when you need to discover or inspect PRs.gh pr view --comments and gh api for fetching existing review context.gh pr comment and gh api to create or update reviews/comments when posting replies or submitting reviews.gh pr merge) unless the user explicitly asks you to.When the user asks to resolve PR comments (e.g. "help me resolve comments" or "address PR feedback"):
git rev-parse --abbrev-ref HEAD) and run gh pr list --head <branch> --json number,title to get the PR for that branch; use that PR number.gh commands to:
gh pr view <number> --json ...).gh pr view <number> --comments or gh api).Creates, edits, and optimizes skills for Claude Code, including drafting, evaluating with test prompts, iterating on performance, and improving skill descriptions for better triggering accuracy.
npx claudepluginhub mikesilvis/ai-skills --plugin github-pr-comment-resolution