git show diff one file code example Example 1: git diff show only files git diff --name-only SHA1 SHA2 Example 2: git show diff in modified file git diff [filename]