Skip to main content

Module worktree

Module worktree 

Source

Structs§

WorktreeEntry

Functions§

clean_merged
Delete worktrees whose branches are merged into default_branch.
create_worktree
git worktree add -b {branch} {path} {base_branch}
is_branch_merged
Check if branch is an ancestor of default_branch (i.e., merged).
list_worktrees
List worktrees via git worktree list --porcelain.
remove_worktree
git worktree remove --force {path} then git branch -d {branch}
to_worktree_infos
Convert WorktreeEntry list to WorktreeInfo list (no sessions yet — populated by refresh_all).