Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

git worktree uses one repo to laid out multiple branches in separate directories.

git worktree add new/path/for/worktree branchname

I now refuse to use git checkout to switch branches, always keep my main branch checked out and updated and always use worktrees to work on features. Love this workflow!



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: