Agent skill

Prcheckloop

by paperclipai in paperclipai/paperclip

Iterate on a GitHub PR until latest-head checks are green or a precise blocker is named.

MITAuto-check passed

Install Prcheckloop

skills CLI
$ npx skills add paperclipai/paperclip --skill prcheckloop -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install paperclipai/paperclip prcheckloop --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/paperclipai/paperclip.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agents/skills/prcheckloop .claude/skills/prcheckloop && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
prcheckloop
GitHub stars
99k
Token cost
~1.5k tokens
SKILL.md length
674 words
Files
1
Skills in repo
60
Repo updated
First seen
Licence
MIT

At a glance

Iterate on a GitHub PR until latest-head checks are green or a precise blocker is named.

  • Works in 8 steps: Identify the PR → Track the latest head SHA → Inventory checks for that SHA → …
  • A PR still has failing
  • SKILL.md covers Scope, Inputs, Workflow and Output, plus 1 more section
  • Calls gh, jq and git

What it does

Prcheckloop is an agent skill from paperclipai/paperclip. Iterate on a GitHub PR until latest-head checks are green or a precise blocker is named. Use when a PR still has failing or pending checks after review fixes, including after greploop.

Its SKILL.md is about 1.5k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It works with GitHub. The repository describes itself as: The open-source app everyone uses to manage agents at work. The licence is MIT.

When your agent uses it

  • A PR still has failing
  • Pending checks after review fixes
  • Including after greploop

Example prompts

  • “/prcheckloop”

Workflow steps

8 steps, taken from the step headings in SKILL.md.

  1. Identify the PR
  2. Track the latest head SHA
  3. Inventory checks for that SHA
  4. Wait for checks to actually run
  5. Investigate failing checks
  6. Fix actionable failures
  7. Push and repeat
  8. Escalate blockers precisely

What it can do on your machine

Read from SKILL.md and the folder at commit b9750b1. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • gh
    • jq
    • git

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md. Its commands use gh and git, which can reach the network depending on how they are called.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Prcheckloop loads about 1.5k tokens when it runs. Until then it costs about 49 tokens; SKILL.md has 674 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~49
When it runs · the whole SKILL.md, loaded when a task matches
~1.5k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from paperclipai/paperclip at commit b9750b1, republished under its MIT licence (© paperclipai). 674 words, ~1,460 tokens.

Download SKILL.mdSave it as .claude/skills/prcheckloop/SKILL.md (or your agent's skills folder).
name
prcheckloop
description
Iterate on a GitHub PR until latest-head checks are green or a precise blocker is named. Use when a PR still has failing or pending checks after review fixes, including after greploop.

PRCheckloop

Get a GitHub PR to a fully green check state, or exit with a concrete blocker.

Scope

  • GitHub PRs only. If the repo is GitLab, stop and use check-pr.
  • Focus on checks for the latest PR head SHA, not old commits.
  • Focus on CI/status checks, not review comments or PR template cleanup.
  • If the user also wants review-comment cleanup, pair this with check-pr.

Inputs

  • PR number (optional): If not provided, detect the PR for the current branch.
  • Max iterations: default 5.

Workflow

1. Identify the PR

If no PR number is provided, detect it from the current branch:

bash
gh pr view --json number,headRefName,headRefOid,url,isDraft

If needed, switch to the PR branch before making changes.

Stop early if:

  • gh is not authenticated
  • there is no PR for the branch
  • the repo is not hosted on GitHub
2. Track the latest head SHA

Always work against the current PR head SHA:

bash
PR_JSON=$(gh pr view "$PR_NUMBER" --json number,headRefName,headRefOid,url)
HEAD_SHA=$(echo "$PR_JSON" | jq -r .headRefOid)
PR_URL=$(echo "$PR_JSON" | jq -r .url)

Ignore failing checks from older SHAs. After every push, refresh HEAD_SHA and restart the inspection loop.

3. Inventory checks for that SHA

Fetch both GitHub check runs and legacy commit status contexts:

bash
gh api "repos/{owner}/{repo}/commits/$HEAD_SHA/check-runs?per_page=100"
gh api "repos/{owner}/{repo}/commits/$HEAD_SHA/status"

For a compact PR-level view, this GraphQL payload is useful:

bash
gh api graphql -f query='
query($owner:String!, $repo:String!, $pr:Int!) {
  repository(owner:$owner, name:$repo) {
    pullRequest(number:$pr) {
      headRefOid
      url
      statusCheckRollup {
        contexts(first:100) {
          nodes {
            __typename
            ... on CheckRun { name status conclusion detailsUrl workflowName }
            ... on StatusContext { context state targetUrl description }
          }
        }
      }
    }
  }
}' -F owner=OWNER -F repo=REPO -F pr="$PR_NUMBER"
4. Wait for checks to actually run

After a new push, checks can take a moment to appear. Poll every 15-30 seconds until one of these is true:

  • checks have appeared and every item is in a terminal state
  • checks have appeared and at least one failed
  • no checks appear after a reasonable wait, usually 2 minutes

Treat these as terminal success states:

  • check runs: SUCCESS, NEUTRAL, SKIPPED
  • status contexts: SUCCESS

Treat these as pending:

  • check runs: QUEUED, PENDING, WAITING, REQUESTED, IN_PROGRESS
  • status contexts: PENDING

Treat these as failures:

  • check runs: FAILURE, TIMED_OUT, CANCELLED, ACTION_REQUIRED, STARTUP_FAILURE, STALE
  • status contexts: FAILURE, ERROR

If no checks appear for the latest SHA, inspect .github/workflows/, workflow path filters, and branch protection expectations. If the missing check cannot be caused or fixed from the repo, escalate.

5. Investigate failing checks

For GitHub Actions failures, inspect runs and failed logs for the current SHA:

bash
gh run list --commit "$HEAD_SHA" --json databaseId,workflowName,status,conclusion,url,headSha
gh run view <RUN_ID> --json databaseId,name,workflowName,status,conclusion,jobs,url,headSha
gh run view <RUN_ID> --log-failed

For each failing check, classify it:

Failure typeAction
Code/test regressionReproduce locally, fix, and verify
Lint/type/build mismatchRun the matching local command from the workflow and fix it
Flake or transient infra issueRerun once if evidence supports flakiness
External service/status app failureEscalate with the details URL and owner guess
Missing secret/permission/branch protection issueEscalate immediately

Only rerun a failed job once without code changes. Do not loop on reruns.

Show full SKILL.md (268 more words)Show less
6. Fix actionable failures

If the failure is actionable from the checked-out code:

  1. Read the workflow or failing command to identify the real gate.
  2. Reproduce locally where reasonable.
  3. Make the smallest correct fix.
  4. Run focused verification first, then broader verification if needed.
  5. Commit in a logical commit.
  6. Push before re-checking the PR.

Do not stop at a local fix. The loop is only complete when the remote PR checks for the new head SHA are green.

7. Push and repeat

After each fix:

bash
git push
sleep 5

Then refresh the PR metadata, get the new HEAD_SHA, and restart from Step 3.

Exit the loop only when:

  • all checks for the latest head SHA are green, or
  • a blocker remains after reasonable repair effort, or
  • the max iteration count is reached
8. Escalate blockers precisely

If you cannot get the PR green, report:

  • PR URL
  • latest head SHA
  • exact failing or missing check names
  • details URLs
  • what you already tried
  • why it is blocked
  • who should likely unblock it
  • the next concrete action

Good blocker examples:

  • external status app outage
  • missing GitHub secret or permission
  • required check name mismatch in branch protection
  • persistent flake after one rerun
  • failure needs credentials or infrastructure access you do not have

Output

When the skill completes, report:

  • PR URL and branch
  • final head SHA
  • green/pending/failing check summary
  • fixes made and verification run
  • whether changes were pushed
  • blocker summary if not fully green

Notes

  • This skill is intentionally narrower than check-pr: it is a repair loop for PR checks.
  • This skill complements greploop: Greptile can be perfect while CI is still red.

© paperclipai, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in .agents/skills/prcheckloop of paperclipai/paperclip.

Open the folder on GitHubat commit b9750b1

Compare with similar skills

Prcheckloop next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Prcheckloop compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Prcheckloop this skillpaperclipai/paperclip99k—~1.5kAutomated safety check: PassMIT
PR Babysitteropeninterpreter/openinterpreter69k3 repos~4.2kAutomated safety check: PassApache-2.0
Diagnosing Superpowers Sessionsobra/superpowers297k3 repos~1.7kAutomated safety check: PassMIT
Greplooponyx-dot-app/onyx32k4 repos~3.3kAutomated safety check: PassMIT
GitHub Deep Researchbytedance/deer-flow84k4 repos~1.3kAutomated safety check: PassMIT
Update V8 Versionopeninterpreter/openinterpreter69k2 repos~845Automated safety check: PassApache-2.0

Similar skills

  • PR Babysitter

    openinterpreter/openinterpreter

    Watches an open GitHub pull request until it merges, handling review comments, diagnosing CI failures and retrying flaky checks along the way.

    69k GitHub starsUsed in 3 repos~4.2k tokens
    DevelopmentAuto-check passed
  • Investigates a session where Superpowers went wrong, reads the transcripts on disk and produces an evidence-cited report, optionally prepared as a bug report for the maintainers.

    297k GitHub starsUsed in 3 repos~1.7k tokens
    Agent WorkflowsAuto-check passed
  • Greploop

    onyx-dot-app/onyx

    Iteratively improves a PR (GitHub), MR (GitLab), or shelved changelist (Perforce) until Greptile gives it a 5/5 confidence score with zero unresolved comments.

    32k GitHub starsUsed in 4 repos~3.3k tokens
    DevelopmentAuto-check passed
  • GitHub Deep Research

    bytedance/deer-flow

    Researches a GitHub repository over four rounds using the GitHub API and web search, then writes a structured markdown report with timeline, metrics and Mermaid diagrams.

    84k GitHub starsUsed in 4 repos~1.3k tokens
    Research & ScienceAuto-check passed
  • Update V8 Version

    openinterpreter/openinterpreter

    Bumps the pinned v8 and rusty_v8 versions in Codex, validates the release-candidate path with the v8-canary check, and traces failures to upstream build changes.

    69k GitHub starsUsed in 2 repos~845 tokens
    DevOps & CloudAuto-check passed
  • Last30days

    mvanhorn/last30days-skill

    Research what people actually say about any topic in the last 30 days.

    64k GitHub stars~7.9k tokensUpdated today
    Research & ScienceAuto-check: notes

More from paperclipai/paperclip

All 60 skills in this repo
  • Garden Inbox

    paperclipai/paperclip

    Scan a Paperclip user's Mine inbox, classify reversible archive candidates, request checkbox confirmation, and archive only accepted selections.

    99k GitHub stars~1.1k tokensUpdated today
    Auto-check passed
  • Paperclip

    paperclipai/paperclip

    Interact with the Paperclip control plane API for task coordination and governance.

    99k GitHub stars~9.6k tokensUpdated today
    Auto-check passed
  • Paperclip

    paperclipai/paperclip

    A skill your agent uses for Paperclip-managed tasks and heartbeats: reading task context, delivering task documents or files, updating completion or blockers, coordinating or delegating work, and…

    99k GitHub stars~17k tokensUpdated today
    Auto-check passed
  • Design Guide

    paperclipai/paperclip

    Paperclip UI design system guide for building consistent, reusable frontend components.

    99k GitHub starsUsed in 1 repo~3.1k tokens
    Auto-check passed
  • Paperclip Page

    paperclipai/paperclip

    Publish static HTML pages and asset folders to the Paperclip S3/CloudFront page host.

    99k GitHub stars~1k tokensUpdated today
    Auto-check passed
  • Paperclip Create Agent

    paperclipai/paperclip

    Create new agents in Paperclip with governance-aware hiring.

    99k GitHub starsUsed in 1 repo~2.1k tokens
    Auto-check passed

Works with

Questions about Prcheckloop

What does Prcheckloop do?

Iterate on a GitHub PR until latest-head checks are green or a precise blocker is named. Prcheckloop is an agent skill from paperclipai/paperclip. Iterate on a GitHub PR until latest-head checks are green or a precise blocker is named.

When should I use Prcheckloop?

Prcheckloop fits situations like: A PR still has failing; pending checks after review fixes; including after greploop.

How do I install Prcheckloop in Claude Code?

Run `npx skills add paperclipai/paperclip --skill prcheckloop -a claude-code`. Or copy the skill folder (.agents/skills/prcheckloop in paperclipai/paperclip) into .claude/skills/prcheckloop in your project. Claude Code loads it when a task matches its description.

How do I install Prcheckloop in Codex?

Run `npx skills add paperclipai/paperclip --skill prcheckloop -a codex`. Or copy the skill folder (.agents/skills/prcheckloop in paperclipai/paperclip) into .agents/skills/prcheckloop in your project. Codex loads it when a task matches its description.

Can I use Prcheckloop in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add paperclipai/paperclip --skill prcheckloop -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/prcheckloop, .gemini/skills/prcheckloop, .github/skills/prcheckloop and .opencode/skills/prcheckloop in your project.

What does Prcheckloop need to run?

Going by SKILL.md and its folder, Prcheckloop needs the command-line tools its instructions call (gh, jq and git).

Does Prcheckloop access the network?

SKILL.md contains no URLs. Its commands use gh and git, which can reach the network depending on how they are called. This is read from the text; nothing was executed.

Is Prcheckloop safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Prcheckloop use?

Prcheckloop is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Prcheckloop use?

About 1.5k tokens (SKILL.md is roughly 5.8k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Prcheckloop?

Skills that share tags, products or a category with Prcheckloop: PR Babysitter (openinterpreter/openinterpreter, 69k stars), Diagnosing Superpowers Sessions (obra/superpowers, 297k stars), Greploop (onyx-dot-app/onyx, 32k stars) and GitHub Deep Research (bytedance/deer-flow, 84k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Prcheckloop?

paperclipai (a GitHub organization) maintains it in paperclipai/paperclip, which has 98,967 GitHub stars. The repository holds 60 skills in this directory. The repository was last updated on October 9, 2026.

Source: paperclipai/paperclip on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.