• atzanteol@sh.itjust.works
      link
      fedilink
      English
      arrow-up
      4
      ·
      1 month ago

      It’s more space efficient - you don’t get another full copy of the repo. The worktree points back to the same .git directory.

      And since it’s in the same repo you can diff between branches with other worktrees without needing to setup remotes for each of them.

    • eldavi@lemmy.ml
      link
      fedilink
      English
      arrow-up
      2
      arrow-down
      1
      ·
      1 month ago

      every time i do this, i have to annotate the old copy somehow.

      i usually use a date and months later i have no clue why i made the copy.