git diff shows changes how to commit modified file code example Example: git show diff in modified file git diff [filename]