{"version":"2.1.314","anchor":"worktree-creation-handles-multiple-worktree-homes","canonical_anchor":"worktree-creation-handles-multiple-worktree-homes","heading":"Worktree creation reworked to handle several possible locations","tier":"notice","area":"Worktrees","scope":"individual","heads_up":false,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.314\/e\/worktree-creation-handles-multiple-worktree-homes","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.314","markdown":"### Worktree creation reworked to handle several possible locations\n\nWorktree placement now comes from an anchor, lookups check several folders, and git worktree add receives its branch arguments consistently\n\n**What**\n\nA worktree is a second working copy of a git repository, in its own folder, that Claude Code can create so work happens apart from your main checkout. How worktrees are placed and created changed:\n\n- Where a worktree is allowed to live is now worked out from an anchor instead of a fixed path from the repository root. The 'Cannot create worktree:' error messages are unchanged.\n\n- Naming, clash detection, repairing leftover worktrees and removal now check several candidate folders, including the anchor's resolved path, instead of one. A leftover is reported as one \"whose .git file points to another location\".\n\n- When creating a worktree, the `--no-track` and branch arguments now go into the same argument list as the rest of the `git worktree add` command, which also gets `--no-checkout` when `worktree.sparsePaths` is set. Before, they were added to a different list.\n\n**Why**\n\nWorktrees may be found and placed differently when the repository's path can be reached in more than one way, and sparse worktrees (ones that check out only some paths) should now receive their branch arguments.\n\n- Area: Worktrees\n- Tier: You'll notice\n- Useful: 1\/5\n- Signal: 1\/5\n- Scope: individual\n- Heads-up: no"}