/backpressured:pr-monitoringfrom backpressured
Monitors an open PR until it cleanly merges, watching CI through flips and addressing conflicts/comments. Use when a PR is open but not yet landed.
Ships in backpressured. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Open is not landed. Green is not merged. A PR you opened is unfinished work until it has actually merged with nothing outstanding — or you have named a blocker only a human can clear. You are the machine that keeps watching so a human doesn't have to babysit the PR; declaring "done" at PR-open (or at a freshly-green CI) is exactly the human-backpressure you exist to replace.
Two traps the base instinct misses even when it resists "open = done":
Not for: opening the PR itself; deciding whether to open one; code review of the diff (that is the reviewer skills). This is purely the watch-until-landed loop.
Report done only when all hold; otherwise keep monitoring or name the blocker:
statusCheckRollup).mergeStateStatus is not DIRTY) and the branch is not stale (BEHIND) — ideally CLEAN.digraph pr_monitor {
"PR open" [shape=box];
"Watch checks to completion" [shape=box];
"All required checks green?" [shape=diamond];
"Read failing logs, fix root cause, push" [shape=box];
"Hold a green minute (≥60s continuously green)" [shape=box];
"Anything flipped red / new check started?" [shape=diamond];
"Comments or conflicts outstanding?" [shape=diamond];
"Address them (push fix / resolve / reply)" [shape=box];
"Merge if authorized" [shape=box];
"Merged?" [shape=diamond];
"STOP: name the human blocker" [shape=octagon];
"Landed clean — report done" [shape=doublecircle];
"PR open" -> "Watch checks to completion";
"Watch checks to completion" -> "All required checks green?";
"All required checks green?" -> "Read failing logs, fix root cause, push" [label="no"];
"Read failing logs, fix root cause, push" -> "Watch checks to completion";
"All required checks green?" -> "Hold a green minute (≥60s continuously green)" [label="yes"];
"Hold a green minute (≥60s continuously green)" -> "Anything flipped red / new check started?";
"Anything flipped red / new check started?" -> "Watch checks to completion" [label="yes — restart clock"];
"Anything flipped red / new check started?" -> "Comments or conflicts outstanding?" [label="no"];
"Comments or conflicts outstanding?" -> "Address them (push fix / resolve / reply)" [label="yes"];
"Address them (push fix / resolve / reply)" -> "Watch checks to completion";
"Comments or conflicts outstanding?" -> "Merge if authorized" [label="no"];
"Merge if authorized" -> "Merged?";
"Merged?" -> "STOP: name the human blocker" [label="no — needs approval/permission"];
"Merged?" -> "Landed clean — report done" [label="yes"];
}
| Need | Command |
|---|---|
| Watch checks (background, 1-min poll, 10-min cap) | timeout 600 gh pr checks <pr> --watch --interval 60 & |
| Structured status in one shot | gh pr view <pr> --json state,mergeStateStatus,reviewDecision,statusCheckRollup |
| Read only the failing job's logs | gh run view <run-id> --log-failed |
| Read review-bot / human comments | gh pr view <pr> --comments |
| Merge when authorized | gh pr merge <pr> --squash (or repo's strategy) |
Key mergeStateStatus values: CLEAN (mergeable), BLOCKED (needs approval/required check), BEHIND (must update branch), DIRTY (conflict), UNSTABLE (a non-required check failing).
Always monitor in the background — never block the session. The user must be able to keep prompting while the PR is watched, so run the watch as a background job (&, or your harness's background-task / re-invoking monitor) and check back on it. A foreground gh pr checks --watch that holds the terminal is wrong here — it freezes the user out.
timeout 600).--interval 60) — not a tight loop, not once-and-walk-away.BACKPRESSURE.md may override the window/interval, and an obviously fast/slow pipeline can adjust — but the background, non-blocking rule always holds.Background ≠ abandoned — the loop is not over until merged.
--log-failed, fix the root cause, push. Do not re-run jobs hoping for a pass — a red check is unresolved work, and a flaky-looking failure on your own change is usually your change. (See [[general-code-review]] if the failure points at a logic/type defect.)BEHIND: update the branch from base, which re-triggers CI — back to watching.BLOCKED, missing approval, no permission): that is a genuine human blocker. STOP and name it precisely ("CI green and mergeable; branch protection needs one human approval") — do not report success.| Rationalization | Reality |
|---|---|
| "PR is open, task done — I'll log off" | Open ≠ landed. The watch has barely started. |
| "Local tests passed, CI will be the same" | CI is a different environment; that's the point of CI. Confirm green on CI. |
| "All 7 checks are green, we're done" | Green ≠ merged, and a 30-second-old green can still flip. Hold the green minute, then merge. |
| "A check went red, just re-run it" | Re-run-until-green hides a real failure. Read the log, fix the cause. |
| "Green now, I can stop watching" | Comments and conflicts land after green. Watch until merged. |
| "I'll report done and mention CI is still running" | A status that depends on an unverified future is a false completion claim. |
"I'll just --watch in the foreground until it's done" | That blocks the session so the user can't prompt. Run it in the background, poll every minute (default 10-min window). |
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
9 skills in this plugin
/backpressured-configSets up backpressure for a project — detects its check/run commands, writes or edits a BACKPRESSURE.md, verifies Playwright, and installs the MCP servers the loop uses. Runs ONLY when the user explicitly invokes `/backpressured:config`; never auto-trigger it./general-code-reviewUse when a backpressured code-review subagent is reviewing a diff for correctness/logic, simplicity/reuse, or test-quality defects — everything except type design. The default reviewer dimension./backpressuredRuns a backpressured automated development loop. Use it ONLY when the user explicitly mentions "backpressured" or "backpressure" — e.g. asking for a "backpressured" loop/run, "do this backpressured", or invoking it by that name — or runs the `/backpressured:goal` command. A bare `/goal`, or any goal-like request that does not mention backpressure, does NOT trigger this loop.npx claudepluginhub lucasfcosta/backpressured --plugin backpressuredOther plugins' skills for the same job