Agent skill
gh-pr-comment-fixer
Fix GitHub PR review comments using the gh CLI: fetch review threads, implement requested changes, run the full test suite, commit and push fixes, then resolve the review threads. Use when asked to address PR comments or review feedback on the current branch.
Install this agent skill to your Project
npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/development/gh-pr-comment-fixer
SKILL.md
Gh Pr Comment Fixer
Overview
Use the gh CLI to retrieve PR review comments for the current branch, apply fixes, verify with the full test suite, and resolve the review threads after pushing.
Workflow
-
Identify the PR for the current branch.
- Prefer
gh pr view --json number,headRefNameand confirm it matches the branch.
- Prefer
-
Retrieve review threads and comments.
- Use
gh pr view --json reviewThreadsandgh pr view --json comments. - Summarize the requested changes and note any questions or ambiguities.
- Use
-
Evaluate each comment.
- Decide if it is reasonable, needs clarification, or should be declined.
- If clarification is needed, ask before changing code.
-
Implement fixes.
- Make minimal, targeted edits.
- Add or update tests if the change warrants it.
- Keep commit scope aligned with a single comment or logical group.
-
Run the full test suite.
- Use the repo standard test command unless instructed otherwise.
- Report failures and decide whether to continue or request input.
-
Commit and push fixes.
- Use a conventional commit message.
- Mention which comments were addressed.
-
Resolve review threads.
- Use
gh pr review --commentfor replies andgh apiorgh pr reviewto resolve threads. - Resolve only after the fix is pushed.
- Use
Notes
- Prefer
gh pr viewandgh pr diffover manual web browsing. - If no PR exists for the current branch, ask the user to open one or provide a PR number.
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
Didn't find tool you were looking for?