Hacker News new | ask | show | jobs
by skydhash 258 days ago
Branch is semantic. The true unit is commit and the tree is applying a set of commits. Branching is just selecting a set of commits for a tree. There’s no wrong or right branch, there is just the matter of generating the wrong patch
2 comments

Branches are mutable and regularly point to a new commit. Branching is selecting an active line of development, a set of commits that change over time.

That's why git also offer tags. Tags are immutable.

That's an important distinction.

see my sibling comment here: https://news.ycombinator.com/item?id=45479690

tl;dr you lose some semantic (and practical capabilities, UX and effectiveness) when you don't capture branch information at commit-level