Skip to content

wtm checkout

This content is for v0.28. Switch to the latest version for up-to-date documentation.

Create a worktree from an existing pull request

Create a worktree from a pull request. A local branch of the PR's name is checked out as-is, keeping commits you never pushed; interactive runs offer to fast-forward it when it is behind origin. Without arguments, shows an interactive picker of open PRs.

wtm checkout [number] [flags]
# Pick among the open pull requests
wtm checkout
# Only the ones waiting for your review
wtm checkout --review
wtm checkout 42
# No prompts, with a JSON result
wtm checkout 42 --yes --output json
--env-from string Override env strategy (example, main, parent)
--from string Parent branch for sync (defaults to the PR base branch)
-h, --help help for checkout
--isolation string How the new worktree stands against its source: isolated (its own ports, compose project and namespaces in shared services, in the .env and at run time) or verbatim (.env kept exactly as copied, run on its source's ports and data); defaults to run.toml's isolation, else isolated
--mine Show only your PRs
--output string Output format: text or json (default "text")
--review Show only PRs where you are requested as reviewer
-y, --yes Skip all prompts; resolve every decision from flags and safe defaults (PR number required)
-q, --quiet Silence human output; errors and the exit code are unaffected, and --output json still emits its document
  • wtm - Orchestrate git worktrees and team dev workflows from the terminal