Skip to main content

Synopsis

Description

Switches to the named branch. Capy pulls that branch’s secrets from the service, then rewrites .env in place with the snippets from the new branch. Switching is blocked while the branch you’re on has work in flight. If .env differs from what keep.lock pins, Capy tells you to run capy first. If keep.lock has changes you haven’t pushed, it tells you to run capy push first. Both checks are skipped when you pass -b. Without -b, checking out a branch that doesn’t exist fails: Capy lists the branches available to you and exits non-zero. With -b, Capy registers the branch first, then switches to it. A brand-new branch with no secrets on the service is seeded from your current .env, and those values stay unpushed until you run capy. capy checkout is disabled in local-only mode - local mode has no server, so there are no branches to switch between.

Flags

Examples

See also

Last modified on August 11, 2026