Paging through deletes adds a cognitive burden when reviewing code.
Thus we have
git config --global alias.deleteless-diff 'diff -M --diff-filter=ACMRTUXB'
and using `git deleteless-diff` is standard practice during code reviews.
However, the filter leaves out delete information altogether, which is
error-prone.
Therefore I'd like to propose adding the -D (or
--omit-delete-contents) option to git diff
that would behave as follows:
$ git rm foo
$ git diff -Ddelete foo
I.e. instead of displaying the contents of the file as a diff minus, a
descriptive message
is displayed -- like with renames.
Thoughts, suggestions?
Can 'diff -M --diff-filter=ACMRTUXB' be improved?
Best regards,
Mart Sõmermaa