You can do this by looking at the unique values ββfrom ls-tree and diff with the --name-only parameters (made in one line, which makes it easier to search and use from history later):
cat <(git ls-tree --name-only -r HEAD) <(git diff --name-only HEAD^ HEAD) | sort | uniq -u
In this example, two revisions are HEAD and HEAD ^. This does not produce side effect output files.
source share