git worktrees step-by-step

May 23, 2023

I use worktrees, but without the bare repo setup described here. May want to look into using it with the gitdir: thing I had never heard of, instead of using the MAIN_BRANCH hack I've been using.

Docs on gitdir: are here and here and probably in some more places

Found via this piece, which has a companion on fetching remote branches which is apparently a shortcoming of the bare repository approach.

I tried to do this and I found the bare repository not to work very well for me at all - it does not want to list remote branches and just generally seems to be a pain to work with. I prefer the tooling I've built.

↑ up