4 ms·
Except, why isn't it "git branch --nocheckout" for the rare cases when you don't want to check out?
by skybrian 14y ago
Except, why isn't it "git branch --nocheckout" for the rare cases when you don't want to check out?
- nessus42 14y agoWhy doesn't "mkdir" cd you into the new subdir unless you type "mkdir --no-cd my-dir"?
- wookietrader 14y agoHere's why: In 95% of the cases you create a git branch, you check it out. In 95% of the cases you create a directory, you do not cd into it.
- nessus42 14y agoFor me, it's about 50% for each. I often create a branch just to snapshot the current state of the branch before squashing or rebasing. When I do this, I do not checkout the new branch, and in fact, most likely I will never check it out. A common mistake people make when bitching about Git, is assuming that their workflow is the only workflow. Git supports a multitude of different workflows, and that fact is both a strength and a weakness.