3 ms·
I'm a little confused how re-cloning a local clone helps you compared to cloning the original remote repo. You can certainly have multiple clones of the remote
by legerdemain 6y ago
I'm a little confused how re-cloning a local clone helps you compared to cloning the original remote repo. You can certainly have multiple clones of the remote repo in multiple locations on disk. To avoid name collisions, you can just not clone to the same parent directory, or choose an alias: `git clone <URL> <ALIAS>`.
However, if cloning your monorepo and switching branches takes a long time, consider `git worktree`. This set of commands allows you to clone a repo once, then keep multiple branches checked out at the same time, in different directories. See this, for example.[1]
[1] https://spin.atomicobject.com/2016/06/26/parallelize-development-git-worktrees/ https://spin.atomicobject.com/2016/06/26/parallelize-develop...
- sebmellen 6y agoThanks, that's even better. I need to work on my Git skills, I'll try this out.