Tour: land a whole batch with orchestrate
madtea orchestrate merges a batch of green PRs and then proves the union works. Each PR may have passed CI in isolation; orchestrate tests whether they still pass together.
Full reference: cli-workflows.md - orchestrate.
The one-liner
madtea orchestrate 88 91 94 --verify "go test ./..."
Give it a list of PR numbers and a verify command. It merges them in order, runs your command against the combined result, and either declares the batch green or names the culprit.
What it does
merge #88 -> merge #91 -> merge #94 -> run your --verify command
green -> done: main holds the tested union
red -> binary-search the merges to find the culprit
-> revert it in a throwaway worktree (your checkout is never touched)
-> re-run verify to prove main is green again
-> report: culprit named, revert PR opened, evidence attached
The batch either lands whole and proven, or main comes out green with the one bad PR identified - never a half-landed pile to untangle by hand.
Your checkout is never touched
orchestrate does its bisection work in an isolated worktree. If it finds a culprit and opens a revert PR, your working tree stays exactly as you left it. The revert is on main via the forge; you see it as a new PR, not a surprise state change in your local branch.
Conflict handling
A merge that conflicts does not wedge your tree. orchestrate reports the conflict and the exact reconcile path, and the recovery runs in its own isolated worktree. If you want to reconcile a conflict and retry, the error message names the conflicting files and the command to run.
When to use it
- You have a backlog of small, green PRs that have never been tested together.
- A monorepo where different PRs touch different packages - passes individually, may conflict at test time.
- Batch-landing a set of dependency-ordered issues where the combined behavior matters.
Flags
madtea orchestrate 88 91 94 --verify "make test" # custom verify command
madtea orchestrate 88 91 94 --verify "go test ./..." --no-revert # merge only, skip bisection and revert
madtea orchestrate 88 91 94 --verify "go test ./..." --strict-overlap # error if any PRs touch the same files
madtea orchestrate 88 91 94 --verify "go test ./..." --max-failures 1 # stop after the first culprit
madtea orchestrate 88 91 94 --verify "go test ./..." --verify-timeout 10m # extend the per-run timeout
--verify CMD- shell command to run after each merge (required).--no-revert- skip bisection and revert on failure; report pass/fail only.--strict-overlap- error and refuse to start if any two PRs touch the same files.--max-failures N- stop after N culprits found and reverted (default 2; 0 = unlimited).--verify-timeout D- per-execution timeout for the verify command (default 5m).--style S- merge strategy (merge, rebase, squash, fast-forward-only); default honors the repo’s configured style.
Part of the guides - madtea documentation.
Canonical source: docs/guides/tour-orchestrate.md in the madtea repo.