Follow Discord
Sweep 29 Sep 2026 · 18:10Z Build v2.1.285 506 read Stable v2.1.280 Latest v2.1.285 Next v2.1.285 Feeds RSS JSON llms.txt llms-full.txt Unofficial

Claude Code v2.1.285 ·

Safer cleanup of leftover git worktrees

Claude Code now removes stale git worktrees more carefully, checking each one before deleting and replacing the old prune step

You'll notice Improvements
JSON All of v2.1.285
You'll noticeTier: how much it should matter to you
2Useful: my rating, 1 to 5
1Signal: worth watching, 1 to 5
WorktreesArea: what it touches
ImprovementsKind: in v2.1.285,
ImprovementsSection of the release
What

A git worktree is an extra working folder linked to the same repository. When Claude Code runs git on a machine you provide, its cleanup of leftover worktrees has changed:

  • stale worktrees are removed with worktree remove --force, skipping ones that cannot be removed because they are Windows reparse points (links to other locations)
  • worktrees are unregistered with a limited, contained step instead of running worktree prune
  • before deleting, the scan checks the worktree's gitdir file, confirms the repository root is the expected one, and compares file identity numbers
Why

These checks lower the risk of deleting the wrong folders, especially on shared or network drives.

How sure we are
Something disagreesSomething we can check disagrees with this entry, or the writer said they could not settle it.
The writer flagged doubtIt is not clear which features run this cleanup.

See this entry in the whole of v2.1.285 →

Feedback