Wilfred / difftastic

a structural diff that understands syntax 🟥🟩
https://difftastic.wilfred.me.uk/
MIT License
21.03k stars 345 forks source link

Consider assuming that line numbers are at least two digits #753

Open Wilfred opened 2 months ago

Wilfred commented 2 months ago

Since the vast majority of files have at least 10 lines, it might improve alignment.

foo.py --- 1/2 --- Python
1 1
2   new_import()

foo.py --- 2/2 --- Python
11 12
12 13 other_change()
Wilfred commented 2 months ago

A better heuristic might be looking at the line number of the last change in the file.