Hacker News new | past | comments | ask | show | jobs | submit login

What you described can't happen. If you merge one branch into another, both branches must exist in the repo. Deleting the feature branch following a merge, wouldn't delete the commits it contained. But even if that weren't the case. That means multiple people would have needed to all delete their feature branch without checking the code they wrote was merged and working. rm can delete code too, would you blame rm for having a confusing interface you just couldn't understand?

Come to think about it, git does warn you when you tried to delete a branch that's not merged into any other branch.




> That means multiple people would have needed to all delete their feature branch

That switch might have done something about rewriting history. Or maybe it was rebase, I never do either of these things. Multiple people (except me) have synchronized after that happened. If interested how we fixed — I’ve copy-pasted couple commands from a chat, sent by a co-worker who knows more about git. These commands pushed my local branch under a new name, then people managed to sort it out with a merge.




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

Search: