Command Reference
June 1, 2026 ยท View on GitHub
Use this page when you already know what kind of action you need.
If you are brand new to Switchman, start with:
switchman reviewfor a zero-config first read of local git worktreesswitchman review --pr-readywhen you need to know whether parallel AI work is safe to mergeswitchman review --pr-ready --all-worktreeswhen agents already ran in local git worktreesswitchman review --pr-ready --from branch-a branch-bwhen agents already ran on branchesswitchman review --pr-ready --from branch-a branch-b --out switchman-review.mdwhen you want a PR handoff fileswitchman gate ciwhen the review looks good and you want a local merge gateswitchman demofor the shortest proof before trying it on a real repo
Review and merge confidence
switchman review
- works without
switchman init; if no Switchman database exists, it reviews local git worktrees from git evidence --pr-readyprints a PR-ready Markdown merge confidence report--all-worktreesreviews all non-main git worktrees from git evidence, even if Switchman did not manage them--from <refs...>reviews existing branches, refs, or worktree names from git evidence--base <branch>chooses the base branch for unmanaged review mode--out <path>writes the PR-ready Markdown report to a file--historyshows retained session history--search <query>filters retained history to matching sessions
switchman gate ci
- runs the repo-level merge gate locally or in CI
- checks file conflicts, semantic conflicts, stale leases, unclaimed changes, and boundary validation state
--github-comment --pr-from-envposts or updates the PR comment with the green/amber/red merge-confidence summary
switchman gate install-ci
- installs a GitHub Actions workflow with a named Switchman PR check
- keeps the Switchman summary visible before the workflow fails the check
- grants
pull-requests: writeso GitHub Actions can post the Switchman PR comment
switchman status
- use this when Switchman managed the run and you are not sure what needs attention next
switchman demo
- creates a self-contained demo repo
- proves an overlapping claim gets blocked
- lands the demo work safely through the queue
- best first command if you want to see the product work before wiring a real repo
Advanced managed coordination
Use these when you want Switchman to create workspaces, assign tasks, manage leases, or govern agents through MCP.
switchman quickcheck
- checks whether the current repo is ready for a managed Switchman run
switchman start "Add authentication"
- plans work, creates agent workspaces, writes MCP config, and starts the managed run
switchman setup
- creates agent workspaces
- initialises the database
- writes
.mcp.jsonand.cursor/mcp.jsonto the repo root and each generated workspace - current agent workspace cap:
10
Useful options:
--agents 3--prefix switchman
switchman init
- initialise in the current git repo without creating extra workspaces
- useful when you want full coordination mode; for existing agent worktrees, start with
switchman review --all-worktrees
switchman task add <title>
switchman task list
switchman task retry <taskId>
switchman task retry-stale
- resets all stale tasks, or all stale tasks for one pipeline, back to
pending - useful after shared-boundary changes invalidate several completed tasks at once
switchman task done <taskId>
switchman task fail <taskId>
switchman lease next
switchman lease list
switchman lease heartbeat <leaseId>
switchman lease reap
switchman lease policy
switchman lease policy set
switchman claim <taskId> <worktree> [files...]
- use this before editing shared files in a managed run
--forceis for operator-led recovery only, not normal agent flow
switchman release <taskId>
switchman scan
Reports and history
switchman insights
- cross-session hotspot reporting for recurring amber-or-worse areas and validation gaps
- useful filters:
--days 30,--json
switchman usage
- reporting for token and cost usage by session, agent, and time window
- useful filters:
--days 30,--session <id>,--agent <name>,--task <id>
switchman usage record
- manual write path for agent/token/cost events when you want to backfill or integrate a custom runner
switchman worktree list
switchman worktree sync
Merge and pipelines
Use this group when work is already running and you need to decide what lands, what waits, or what needs recovery.
switchman queue add
switchman queue list
switchman queue status
switchman queue run
- supports
--follow-planto only auto-run currentland_nowcandidates - supports
--merge-budget <n>to cap how many successful merges one run is allowed to consume
switchman queue retry
switchman queue remove
switchman pipeline start
- creates one tracked pipeline with structured subtasks
- use this when the work is too broad for one safe task
switchman pipeline exec
- runs the pipeline through one agent command and records structured outcomes per task
switchman pipeline status
- use this when you need to understand what is blocked, stale, policy-gated, or ready to land
switchman pipeline pr
switchman pipeline bundle
- writes reviewer-ready bundle artifacts for a pipeline
- adds GitHub-friendly step summary and output keys with
--github
switchman pipeline comment
- posts or updates the landing summary on a PR
- can read the PR number from GitHub Actions with
--pr-from-env
switchman pipeline sync-pr
- bundles pipeline artifacts, updates the PR comment, and writes GitHub outputs together
- useful as the single CI handoff command for pipeline reviews
switchman pipeline publish
- creates the hosted PR from the generated bundle once the governed landing state is ready
Useful explain and recovery commands in this area:
switchman explain queue <itemId>switchman explain landing <pipelineId>switchman pipeline land <pipelineId> --refreshswitchman pipeline land <pipelineId> --recoverswitchman pipeline land <pipelineId> --resume