so-fancy / diff-so-fancy

Good-lookin' diffs. Actually… nah… The best-lookin' diffs. :tada:
MIT License
17.39k stars 335 forks source link

Changes at beginning and end of the line get not detected #373

Open fbruetting opened 4 years ago

fbruetting commented 4 years ago

Is you see in my screen shot, I commeted out two lines and also removed their comments. dsf however doesn’t detect that and instead renders them as complete new lines.

Meld for example detects that correctly and renders them as partly changed lines.

Bildschirmfoto von 2020-05-13 18-41-01

OJFord commented 4 years ago

You can configure diff-highlight (be sure it's on your $PATH - it's usually distributed with git - and there are examples for configuring the colours in the readme) so that the comments and added comment characters would be highlighted differently to show the line is 'changed' rather than 'completely' different, but there is currently no mangling of the diff contents itself. (And if this were implemented, I'm sure it would be behind a config option.)