agentleFS
euxxeuxx/claude-skills-for-copilot/skills/gh-address-comments/SKILL.md

gh-address-comments

Skill4 starsChanged 7 months agoMITView on GitHub

Fetch all review comments and threads on the current branch's open GitHub PR using the gh CLI, present a numbered summary, and address the ones the user selects.

32 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use email-draft-polish, codebase-migrate and 10 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • ComposioHQSkill

    email-draft-polish

    Draft, rewrite, or condense emails with target tone, length, and audience; use for cold outreach, replies, status updates, or escalations where clarity and brevity matter.

    Also in 4 projects that use this

  • ComposioHQSkill

    codebase-migrate

    Run large codebase migrations and multi-file refactors. Uses the Composio CLI to coordinate issue tracking, batched PRs, and CI verification while the agent executes the transforms locally across hundreds of files.

    Also in 4 projects that use this

  • petestewartSkill

    datadog-logs

    Query Datadog logs via the Logs Search API v2. Use when the user asks to "check the logs", "search logs", "find errors in Datadog", "look up logs for", "show me production logs", "check for errors", "search Datadog", or any request involving log search, error investigation, or production debugging that requires Datadog log data.

    Also in 3 projects that use this

  • MicrosoftSkill

    deploy-pipeline

    Triggers a Power Platform Pipeline deployment run for a Power Pages solution. Selects a target stage, validates the package, optionally configures deployment settings (environment variables, connection references), then deploys and polls for completion. Use when asked to: "deploy pipeline", "run pipeline", "trigger deployment", "deploy to staging", "deploy to production", "run power platform pipeline", "deploy solution via pipeline", "promote solution", "push to staging", "push to production".

    Also in 3 projects that use this

  • +8 more from ComposioHQ

The file

We split this skill into the rules it gives an agent

7 rules. 0 are common, 5 are distinctive, and 2 are very specific to this project.

  • 0

    Common

    Most of the 30 edited versions we read keep these.

  • 5

    Distinctive

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Verify gh authentication before doing anything else:

    line 14
  2. Very specific:

    If unauthenticated, ask the user to run gh auth login, then stop.

    line 20
  3. Distinctive:

    Run the following to get all review threads (inline) and conversation comments:

    line 38
  4. Distinctive:

    If GraphQL is unavailable, fall back to:

    line 65
  5. Distinctive:

    If the user already provided numbers in the skill argument, proceed with those.

    line 85
  6. Distinctive:

    Read the relevant file and context.

    line 93
  7. Distinctive:

    After all fixes, provide a brief summary listing which comments were addressed and any that were skipped (with reason).

    line 99

“Common” is measured: kept by at least 6 in 10 of the 30 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Address PR Review Comments

Fetch all review comments for the current branch's open PR, present a numbered summary, and apply fixes for the comments the user selects.

Prerequisites

Verify gh authentication before doing anything else:

gh auth status

If unauthenticated, ask the user to run gh auth login, then stop.

Workflow

1. Resolve the PR

# if the user specified a PR number or URL:
gh pr view <number-or-url> --json number,url,headRefName

# otherwise (current branch):
gh pr view --json number,url,headRefName

Extract owner and repo from the returned url field — PR URLs have the form https://github.com/<owner>/<repo>/pull/<number>, so split on / to get the 4th and 5th segments. These are the base (target) repository coordinates, and are reliable even for cross-fork PRs.

2. Fetch comments

Run the following to get all review threads (inline) and conversation comments:

gh api graphql -f query='
query($owner:String!, $repo:String!, $number:Int!) {
  repository(owner:$owner, name:$repo) {
    pullRequest(number:$number) {
      number url title state
      comments(first:100) {
        nodes { id body author { login } createdAt }
      }
      reviews(first:100) {
        nodes { id state body author { login } submittedAt }
      }
      reviewThreads(first:100) {
        nodes {
          id isResolved isOutdated path line
          comments(first:100) {
            nodes { id body author { login } createdAt }
          }
        }
      }
    }
  }
}' -F owner=<owner> -F repo=<repo> -F number=<pr-number>

If GraphQL is unavailable, fall back to:

gh pr view <pr-number> -R <owner>/<repo> --json reviews,reviewRequests,comments

Note: the fallback output does not include thread-level isResolved/isOutdated fields. In fallback mode, treat all returned comments as actionable.

3. Present a numbered summary

List every unresolved comment/thread (or all comments in fallback mode) with a number, author, file/line (if inline), and a one-line description of the requested change. Example:

1. @alice [src/auth.ts:42] — Use bcrypt instead of MD5 for password hashing
2. @bob — Nit: rename `doThing` to `processPayload` for clarity
3. @alice [src/auth.ts:88] — Add input validation before DB query

4. Ask which to address

If the user already provided numbers in the skill argument, proceed with those. Otherwise ask:

Which comments should I address? (e.g. "1 3" or "all")

5. Apply fixes

For each selected comment:

  • Read the relevant file and context.
  • Apply the requested change.
  • Note any cases where the comment is unclear or the fix has side effects — confirm with the user before proceeding.

6. Summarize

After all fixes, provide a brief summary listing which comments were addressed and any that were skipped (with reason).

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.