I am trying to capture the differences across file changes by using
git diff --exit-code --minimal <file>
the problem is that this generates too much output. Let's say I just add a new line on the beginning of the file, the rest remains the same (just in a new line)
the git diff command will output (+) for all lines (new one + all existing ) and also (-) for all existing lines.
I do understand that the whole file changed (all existing lines move 1 line down), but must be a smarter way that can see ignore these "differences" just like kdiff3 can do.
So the only difference that I am interested is the new line that I added (or potentially also a code change in the existing lines).
Any idea how this can be archived?