Adam K Dean

List all files changed in last commit

Published on 8 February 2016 at 10:53 by Adam

List all files changed in the last commit by using git diff-tree on HEAD.

git diff-tree --no-commit-id --name-only -r HEAD

For example, if you changed README.md in your last commit:

adam@macbook:project (master) $ git diff-tree --no-commit-id --name-only -r HEAD
README.md


This post was first published on 8 February 2016 at 10:53. It was filed under archive with tags git, snippet.