SHEPHERDdocs Search the docs/ v0.5.3-beta
On this pageBranches and worktrees

Branches and worktrees

Create a branch or a worktree and remove one safely.

Works inDesktop appTerminal UICLI

Branches and worktrees

$ shepherd git branch feat/login
created branch feat/login

$ shepherd git worktree add ../wt-login --branch feat/login-ui
worktree /path/to/wt-login on feat/login-ui

$ shepherd git status
BRANCH          STATUS      SYNC        AGENT  PR  PATH
master          dirty (2)   up to date  -      —   /path/to/repo
feat/login-ui   clean       up to date  -      —   /path/to/wt-login

$ shepherd git worktree remove ../wt-login
removed worktree ../wt-login

Removing refuses the main checkout, a worktree with uncommitted changes, and one a live agent works in. Publishing a branch is a separate, deliberate step: shepherd git publish <branch> only works on a subtask that is waiting for your approval.

Was this page useful?Suggest an edit on GitHub