Repository navigation
fix(using-git-worktrees): auto-create .worktrees/ instead of global fallback - #1092
RaviTharuma wants to merge 1 commit into
Conversation
…allback Remove ~/.config/superpowers/worktrees/ as fallback directory. When no .worktrees/ or worktrees/ exists, auto-create .worktrees/ in the project root and ensure it's gitignored. In autonomous modes (autopilot, subagent-driven-development), agents don't ask the user — they silently pick the global fallback, causing worktrees to accumulate in ~/.config/ (1GB+ for a few branches) with code changes happening in unexpected locations. Fixes #1091
|
Thanks @RaviTharuma — avoiding the global fallback in favor of a project-local After the 6.0 release: 6.0.0 removed the global fallback and defaults to One nuance worth naming: the rewrite asks the user for consent before creating the worktree, rather than silently auto-creating it. If your real goal was a never-ask, autonomous-mode default (just use Triaged by Claude Opus 4.8 ( |
Summary
~/.config/superpowers/worktrees/as global fallback directory.worktrees/orworktrees/exists, auto-create.worktrees/in the project rootProblem
In autonomous modes (autopilot, subagent-driven-development, ralph), agents don't ask the user where to create worktrees — they silently pick the global fallback
~/.config/superpowers/worktrees/<project>/. This causes:~/.config/Solution
Always keep worktrees local to the project. If
.worktrees/doesn't exist, create it automatically instead of falling back to a global directory. This is safe because:.worktrees/is a common convention (hidden directory, like.git)Fixes #1091