Git · Concept
Detached HEAD
Git worktree lets one repository have several working directories. Each worktree can check out a different branch or commit while sharing the repository's data.
Last updated
Syntax
git worktree add <path> [<commit-ish>]
git worktree list
git worktree remove <worktree>In-depth API docs are only for subscribers: parameters, examples, common mistakes and interview practice.
SubscribeRelated
git worktree addgit worktree listgit worktree lockgit worktree movegit worktree prunegit worktree removegit worktree repairdetached HEAD