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 ·

Forced removal of agent worktrees now checks for links pointing outside the repository

Force-deleting an agent's worktree now refuses when the path goes through a link or no longer matches, and cleans up only stale git records

You'll notice Improvements
JSON All of v2.1.285
You'll noticeTier: how much it should matter to you
1Useful: 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 worktree is an extra working copy of a git repository that lives in its own folder. Claude Code can create one for an agent to work in. When Claude Code force-deletes one of these worktrees, it now first checks what the stored folder path really points to. It refuses to delete anything in two cases:

  • The path reaches into the repository through a link, meaning a shortcut-like file system entry, that comes from outside the repository.
  • The folder it checked is not the same one that is actually at that path.

In both cases nothing is force-deleted. The message asks you to remove the link or the folder yourself, or to try again.

Git keeps a list of worktrees it knows about. When entries in that list are out of date, Claude Code now removes just those entries. Before, it only checked that the worktree's git data linked back to the repository and then told git to clean up every out-of-date entry at once.

Why

These checks stop a forced deletion from following a link and deleting files outside the repository by mistake.

See this entry in the whole of v2.1.285 →

Feedback