{"version":"2.1.290","anchor":"worktree-registration-drop-leaves-folders-that-contain-git-f","canonical_anchor":"worktree-registration-drop-leaves-folders-that-contain-git-f","heading":"Removing a worktree no longer deletes folders that hold git's own files","tier":"notice","area":"Worktrees","scope":"individual","heads_up":false,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.290\/e\/worktree-registration-drop-leaves-folders-that-contain-git-f","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.290","markdown":"### Removing a worktree no longer deletes folders that hold git's own files\n\nWhen dropping a worktree, Claude Code now leaves its folder in place with a warning if it holds git's own files\n\n**What**\n\nA worktree is an extra working copy of a git repository in its own folder. When Claude Code drops a worktree's registration and the folder holds files that belong in a git directory (`objects`, `config`, `packed-refs`, `hooks` or `worktrees`), it now leaves the folder in place and shows a warning. Git deletes it on its next prune or `git gc`.\n\nBefore, Claude Code removed the whole folder, and if that failed, removed only the files git writes there.\n\n**Why**\n\nThis avoids deleting a folder that may still contain your own data.\n\n- Area: Worktrees\n- Tier: You'll notice\n- Useful: 2\/5\n- Signal: 1\/5\n- Scope: individual\n- Heads-up: no"}