Get the latest tech news
How I Use Git Worktrees
There are a bunch of posts on the internet about using git worktree command. As far as I can tell, most of them are primarily about using worktrees as a replacement of, or a supplement to git branches. Instead of switching branches, you just change directories. This is also how I originally had useed worktrees, but that didn't stick, and I abandoned them. But recently worktrees grew on me, though my new use-case is unlike branching.
Note that it is crucial that the fuzzing tree operates in the detached head state (-d flag for git switch). I am also sympathetic to the argument that, like the staging area and the stash, git branches are a miss feature, but I haven ’ t made the plunge personally yet. TL;DR: consider using worktrees not as a replacement for branches, but as a means to manageconcurrency in your tasks.
Or read this on Hacker News