Git check which files are committed

In this article let’s discuss about Git check which files are committed. Let’s go through the following methods without any delay.

Method 1:

git diff --name-only HEAD HEAD~1

If you are facing any issues with the above approach then try the alternative that is given below. It may look similar by have a try!

Method 2 :

$ git diff-tree --no-commit-id --name-only -r bd61ad98
index.html
javascript/application.js
javascript/ie6.js

Hope the above solution works.

Realted Posts : List of files in git commit