t4203: make blame output massaging more robust
authorJunio C Hamano <redacted>
Thu, 14 Jan 2021 20:21:55 +0000 (12:21 -0800)
committerJunio C Hamano <redacted>
Fri, 15 Jan 2021 05:54:52 +0000 (21:54 -0800)
commit2d02bc91c0aa1ced659a21ce75befcd033a4f923
tree2ba8a3e5358485a39896fabb926de482fc71b8e8
parent97f4b4c4e79f7726acca50971b4cf851a3219347
t4203: make blame output massaging more robust

In the "git blame --porcelain" output, lines that ends with three
integers may not be the line that shows a commit object with line
numbers and block length (the contents from the blamed file or the
summary field can have a line that happens to match).  Also, the
names of the author may have more than three SP separated tokens
("git blame -L242,+1 cf6de18aabf7 Documentation/SubmittingPatches"
gives an example).  The existing "grep -E | cut" pipeline is a bit
too loose on these two points.

While they can be assumed on the test data, it is not so hard to
use the right pattern from the documented format, so let's do so.

Signed-off-by: Junio C Hamano <redacted>
t/t4203-mailmap.sh
git clone https://git.99rst.org/PROJECT