3 ms·
A line is a unit of change that git can report on. If it's a separate file that is scoped to some specific concern, sure. But its tgat grouping by concern that
by nonethewiser 4y ago
A line is a unit of change that git can report on.
If it's a separate file that is scoped to some specific concern, sure. But its tgat grouping by concern that is key. Not separation into another file. Extracting ra dom bits of code into separate files would be _worse_.
- swsieber 4y ago> A line is a unit of change that git can report on. Yes and no. Git doesn't store lines, it stores files. Git diff knows how to spit out line changes by comparing files. So to run git blame on a 10k line file you're reading multiple versions of that 10k file and comparing. It's slow. Worse still is that trying to split said file up while trying to preserve history won't make the git blame any faster.
- karamanolev 4y agoYes and yes. While agree with the general points, note that they didn't say "unit that git stores", but "unit git can report on". Git can totally report on lines as a unit of change.