stacked-mr
Autonomous AFK mode: build a stack of owner-scoped PRs/MRs, then batch-review them to the bar. Human merges. Use on /stacked-mr or 'stack PRs'.
Install
mkdir -p .claude/skills/stacked-mr && curl -L -o skill.zip "https://agentskills.codes/api/skills/download/13604" && unzip -o skill.zip -d .claude/skills/stacked-mr && rm skill.zipInstalls to .claude/skills/stacked-mr
Activation
This is the description your AI agent reads to decide when to run this skill — the better it matches your request, the more reliably it fires.
Autonomous AFK mode: build a stack of owner-scoped PRs/MRs, then batch-review them to the bar. Human merges. Use on /stacked-mr or 'stack PRs'.About this skill
/stacked-mr — Stacked PR/MR Pass
Builds a stack of PRs/MRs without reviewing each one immediately, then runs a
batch review pass at the end. The canonical owner, knowledge, artifact, and
follow-up contract is
docs/workflow/agent-process.md.
Stack Shape
main
-> 0012-first-ticket PR #1 base: main
-> 0013-second-ticket PR #2 base: 0012-first-ticket
-> 0014-third PR #3 base: 0013-second-ticket
Each PR/MR diff is against its parent branch. The human merges bottom-up.
Phase 1 — Build Stack
For each runnable ticket:
- Pick the next
now/nextticket by priority within the requested scope. - Confirm exactly one owner agent. If work needs multiple owners, split into linked tickets before building.
- Set status
in-progress. - Run the knowledge phase from
docs/workflow/agent-process.md. - Branch from the current stack tip.
- Implement TDD-first and commit.
- File owner-scoped follow-up tickets for deferred work.
- Run local smoke checks and inspect the diff.
- Push the feature branch.
- Open a PR/MR with base set to the parent branch.
- Link the PR/MR URL into the ticket and update the stack ledger.
Do not run the code-review agent during this phase except for explicit
trust-critical escape hatches.
Phase 2 — Batch Review
- Refresh forge state for every PR/MR in the ledger.
- Run one
code-reviewagent pass per PR/MR in isolated worktrees. - Collect verdicts and review artifacts.
- Fix
request-changesbranches, re-review only affected PRs/MRs, and restack children with--force-with-leaseto feature branches only.
Continue Conditions
- Runnable scoped tickets remain: keep building.
- True human-only blocker: file HITL and continue another lane.
- PR/MR cannot reach the bar after reasonable cycles: mark the ticket
stuckwith the artifact path and continue independent work. - Scoped backlog exhausted: finish batch review and summarize.
Summary Format
Stack of N PRs/MRs, merge bottom-up:
#1 0012-first-ticket base: main approve / tests pass
#2 0013-second-ticket base: 0012-first-ticket request-changes
Include PR/MR URLs, ticket ids, owners, bases, verdicts, test status, HITL items, delegated artifact paths, and follow-up tickets.
Hard Rules
- Never merge.
- Every PR/MR reaches the review bar before final handoff.
- Force-push only feature branches and only with
--force-with-lease. - TDD-first for every implementation ticket.
- Batch reviews run in isolated worktrees.