MCPcopy Create free account
hub / github.com/git/git / repair_worktrees_after_gitdir_move

Function repair_worktrees_after_gitdir_move

worktree.c:753–761  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

751}
752
753void repair_worktrees_after_gitdir_move(const char *old_path)
754{
755 struct worktree **worktrees = get_worktrees_internal(1);
756 struct worktree **wt = worktrees + 1; /* +1 skips main worktree */
757
758 for (; *wt; wt++)
759 repair_worktree_after_gitdir_move(*wt, old_path);
760 free_worktrees(worktrees);
761}
762
763static int is_main_worktree_path(const char *path)
764{

Callers 1

separate_git_dirFunction · 0.85

Calls 3

get_worktrees_internalFunction · 0.85
free_worktreesFunction · 0.85

Tested by

no test coverage detected