agentleFS
StormixStormix/transcripts-mcp/.agents/skills/fix-pr/SKILL.md

fix-pr

Skill8 starsChanged 2 months agoMITView on GitHub

Fix PR Comments

15 other projects use a version of this, 1 of them edited.

Adopted by

Most recently taken up by

Used with

Projects with it also use review-pr and release.

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.
  • DockerSkill

    review-pr

    Review one or more incoming Docker documentation pull requests as a maintainer. Independently validate technical claims, assess editorial fit and information architecture, choose a verdict, and draft exact inline or PR-wide feedback behind a confirmation gate. Use for requests such as "review PR 123", "is this PR correct?", "does this information belong here?", "validate this PR", or "help review backlog PRs". Do not use to maintain or fix a PR you own; use maintain-pr for that.

    Also in 4 projects that use this

  • MicrosoftSkill

    release

    Use ONLY when the user explicitly asks to cut/publish a Huabu desktop release or tag a version. Performs an outward action — bumps the version in apps/desktop/package.json, commits + annotated-tags vX.Y.Z, and pushes the branch + tag. That tag push auto-builds the macOS/Windows installers and publishes a GitHub Release. Provides `status`, `bump`, `tag-push`, and a one-command `run` (bump → tag-push).

    Also in 3 projects that use this

The file

We split this skill into the rules it gives an agent

11 rules. 0 are common, 10 are distinctive, and 1 is very specific to this project.

  • 0

    Common

    Most of the 13 edited versions we read keep these.

  • 10

    Distinctive

    This author's own choices. Worth a look.

  • 1

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    If the user says "skip all remaining", skip the rest of the prompts and only apply already-confirmed fixes.

    line 56
  2. Distinctive:

    Wait for all user responses before proceeding to the fix step.

    line 58
  3. Distinctive:

    Read the relevant file(s)

    line 64
  4. Distinctive:

    Follow all project coding conventions from 030-coding-style

    line 67
  5. Distinctive:

    Do not make unrelated changes

    line 68
  6. Distinctive:

    After all fixes are applied:

    line 70
  7. Very specific:

    Use gh CLI for all GitHub interactions

    line 95
  8. Distinctive:

    Never modify files not related to a specific comment being addressed

    line 96
  9. Distinctive:

    If a comment is unclear, err on the side of asking rather than guessing

    line 97
  10. Distinctive:

    Do not create a changeset unless a fix qualifies per 090-changesets

    line 99
  11. Distinctive:

    Run lint and format

    line 111

“Common” is measured: kept by at least 6 in 10 of the 13 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

Fix PR Comments

Review all open comments on the current branch's pull request, rank them by relevance, prompt for confirmation where ambiguous, then apply fixes.

Instructions

1. Gather Branch and PR Context

echo "=== BRANCH ===" && git rev-parse --abbrev-ref HEAD && echo "=== PR INFO ===" && gh pr view --json number,title,url,state,headRefName,baseRefName && echo "=== PR COMMENTS ===" && gh pr view --json comments --jq '.comments[] | {author: .author.login, body: .body, createdAt: .createdAt}' && echo "=== PR REVIEW COMMENTS ===" && gh pr view --json reviews --jq '.reviews[] | {author: .author.login, body: .body, state: .state, submittedAt: .submittedAt}' && echo "=== PR DIFF COMMENTS ===" && gh api "repos/{owner}/{repo}/pulls/$(gh pr view --json number --jq '.number')/comments" --jq '.[] | {author: .user.login, body: .body, path: .path, line: .line, diff_hunk: .diff_hunk, created_at: .created_at}'

2. Rank Comments by Relevance

Analyze all gathered comments and categorize them:

Priority tiers:

  • P1 - Must fix: Bug reports, broken functionality, security issues, failing tests, incorrect logic
  • P2 - Should fix: Code style violations against project conventions, missing error handling, performance concerns, unclear naming
  • P3 - Consider: Nitpicks, optional suggestions, cosmetic preferences, subjective style opinions

Display a ranked list grouped by priority:

P1 (Must Fix):
  [1] <file>:<line> — <author>: "<comment body>"
  ...

P2 (Should Fix):
  [2] <file>:<line> — <author>: "<comment body>"
  ...

P3 (Consider):
  [3] <file>:<line> — <author>: "<comment body>"
  ...

3. Prompt for Confirmation on Ambiguous Comments

For each P2 and P3 comment, ask the user:

Comment [N] — <author> on <file>:<line>: "<comment body>"

Fix this? (yes / no / skip all remaining)

  • P1 comments are fixed automatically without prompting.
  • P2/P3 comments require explicit user confirmation.
  • If the user says "skip all remaining", skip the rest of the prompts and only apply already-confirmed fixes.

Wait for all user responses before proceeding to the fix step.

4. Apply Fixes

For each confirmed comment (all P1s + user-confirmed P2/P3s):

  • Read the relevant file(s)
  • Understand the context from the diff hunk
  • Apply the minimal, focused fix that addresses the comment
  • Follow all project coding conventions from 030-coding-style
  • Do not make unrelated changes

After all fixes are applied:

pnpm lint:fix
pnpm format:fix

5. Summarize

Show a concise summary:

Fixed:
  [1] <file>:<line> — <brief description of fix>
  ...

Skipped:
  [N] <file>:<line> — <reason or "user skipped">
  ...

Then suggest staging and committing with the /commit command.

Key Points

  • Use gh CLI for all GitHub interactions
  • Never modify files not related to a specific comment being addressed
  • If a comment is unclear, err on the side of asking rather than guessing
  • Respect all rules in .cursor/rules/ when applying fixes
  • Do not create a changeset unless a fix qualifies per 090-changesets

Example Usage

User: "fix pr", "review pr comments", or /fix-pr

Response:

  1. Fetch branch, PR metadata, and all comment types
  2. Rank and display comments by priority
  3. Prompt user for P2/P3 confirmations
  4. Apply all approved fixes
  5. Run lint and format
  6. Show summary and suggest commit

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.