Skip to main content

linked_worktree_paths

Function linked_worktree_paths 

Source
pub fn linked_worktree_paths(git_dir: &Path) -> Vec<PathBuf>
Expand description

Checkout directories of linked worktrees that still exist.

Where a worktree lives is a matter of local convention – .worktrees/, .claude/, a sibling directory – and any of those may be hidden. Guessing the directory name means missing whichever convention was not guessed, so the records are read instead. Each record’s [GITDIR_POINTER] names the .git file inside the checkout, whose parent is the checkout itself.