fix-pr

fix-pr is a skill for Claude Code from bjcoombs/ai-native-toolkit. It costs 19 tokens per session (829 once invoked), scanned A, original, Apache-2.0.

An automated pull-request repair loop that checks CI results and review comments, makes fixes, and repeats until the pull request is ready for a person to review.

In plain words
What is it for?
Use it to bring the current branch's GitHub pull request to a merge-ready state by syncing the base branch, fixing reported problems, pushing changes, and checking the results again.
Why use it?
It removes the need to manually watch checks, respond to comments, and repeat the fix-and-push cycle. It does not merge the pull request automatically.

Skill for Claude Code

Written for Claude Code: disable-model-invocation in frontmatter.

Part of the ai-native-toolkit plugin — 21 skills, 2 commands, 9 agents shipped together

Good fit Use it to bring the current branch's GitHub pull request to a merge-ready state by syncing the base branch, fixing reported problems, pushing changes, and checking the results again.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/bjcoombs/ai-native-toolkit/fix-pr
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add bjcoombs/ai-native-toolkit --skill fix-pr
Clone the repo
git clone --depth 1 https://github.com/bjcoombs/ai-native-toolkit

Made for: Claude Code.

Or install ai-native-toolkit, the plugin that ships this one along with the rest of its 21 skills, 2 commands, 9 agents.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for fix-pr

README.md
[![agentmods](https://agentmods.dev/badge/skills/bjcoombs/ai-native-toolkit/fix-pr/github.svg)](https://agentmods.dev/skills/bjcoombs/ai-native-toolkit/fix-pr)
Your own site
<a href="https://agentmods.dev/skills/bjcoombs/ai-native-toolkit/fix-pr"><img src="https://agentmods.dev/badge/skills/bjcoombs/ai-native-toolkit/fix-pr/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for fix-pr

Your own site · 80×15
<a href="https://agentmods.dev/skills/bjcoombs/ai-native-toolkit/fix-pr"><img src="https://agentmods.dev/badge/skills/bjcoombs/ai-native-toolkit/fix-pr.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 19 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 829 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00019 $0.00829
Opus 5.5 $0.00008 $0.00332
Sonnet 5.5 $0.00004 $0.00166
Haiku 4.5 $0.00002 $0.00083

Measured 3d ago against content hash 9c528c227b4e, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

fix-pr scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/fix-pr/SKILL.md · 106 lines

How it starts

The opening of the file, as written. The whole thing — 106 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Fix PR Autonomously

Enter autonomous PR review loop for the current branch's PR. Loops until the PR is merge-ready across ALL criteria, not just CI.

Windows: run the bash blocks below in Git Bash, which ships with Git for Windows. Installs, PATH notes and the make-free commands are in the Windows setup guide.


What this does

Drive the current branch's PR to merge-ready across all six criteria, then stop for human review (this command does not auto-merge).

Use the pr-review-merge skill: it owns the 6 ready criteria, thread-resolution rules, shell pitfalls, base-sync-first, and the background CI watcher. Pass the current PR number (gh pr view --json number --jq '.number') and the base branch (gh repo view --json defaultBranchRef --jq '.defaultBranchRef.name'), plus any bot rules from the project's Marathon Configuration.


Protocol

  1. Autonomous Loop (DO NOT ask for permission between iterations):

    • Sync base branch, check all 6 criteria, fix issues, push
    • Report: "Iteration N: Fixed X issues" or "Iteration N: Waiting for CI"
    • Loop until all green
  2. Stop when ALL 6 criteria met:

    • Report: "PR #X: All criteria met, ready for human review"
    • Include status footer
    • STOP
  3. Only ask for help if:

    • Genuinely blocked (ambiguous merge conflict, unclear review feedback)
    • After 5+ iterations with no progress
    • Need design decision from user

Example Output

🔄 Iteration 1: Checking PR #123...
   ⚠️ Merge conflict with base branch in App.tsx — resolving (accept both sides)
   ❌ CI: TypeScript errors in user.service.ts
   ❌ CodeRabbit: 2 unresolved threads (missing error handling)
   Fixing...

🔄 Iteration 2: Checking PR #123...
   ✅ In sync with base branch
   ✅ CI passing
   ❌ CodeRabbit: 1 remaining thread (async pattern)
   Fixing...

🔄 Iteration 3: Checking PR #123...
   ✅ In sync with base branch
   ✅ CI passing
   ✅ All threads resolved
   ✅ No unaddressed comments

✅ PR #123: All 6 criteria met, ready for your review!

---
## 📍 Current Work

🔗 **PR**: #123 - Add payment processing
   https://github.com/org/repo/pull/123

📊 **Latest**: All criteria met after 3 iterations

Read the full file on GitHub · 106 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 3d ago Changed 9c528c227b4e
  2. 12d ago Changed · +2 lines 6c73530ea74e
  3. 1mo ago First seen · 104 lines · 19 tokens per session scan A 68ecb48550b5

Subscribe to this mod's changes

fix-pr is a skill published in the GitHub repository bjcoombs/ai-native-toolkit (37 stars, last pushed 2d ago), licensed Apache-2.0. It adds 19 tokens to every session and 829 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-10-09.

Related

fix-pr compared with skills from other repositories

fix-pr next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
fix-prbjcoombs/ai-native-toolkitSkill372d agoApache-2.0A19Claude Code
babysitmichael-denyer/pstack-claudeSkill5.2ktodayMITA61Claude Code
make-pr-easy-to-reviewmichael-denyer/pstack-claudeSkill5.2ktodayMITA57Claude Code
pr-describeMuhammadUsmanGM/claude-code-best-practicesSkill1181mo agoMITA44Claude Code
sealAlexander-Tyagunov/magicianSkill161mo agoMITA33Claude Code
pr-summaryberekvolgyipeter/dotclaudeSkill2todayMITA77Claude Code
pr-workflowMikedev115/AetoxSkill481mo agononeA35Claude Code, Codex