1

Say I have made a series of commit for a certain project, so when I git log --oneline it produces the following

e61c4fb Wrote the special problem review of related literature.
eb584ba Wrote the special problem objectives.
8d2dd52 Added more research papers
72a2d27 Fixed the bug during the removal of parent chromosomes in ga_wknn and saga_wknn
d7467df Added as the k in KNN as a parameter in the constructor of each application.
2293f43 Added a simulation result.
bdfcf41 Done with adding Introduction Comments

Next I would like to see the files that has been added, modified, deleted in one of those commits. I've tried

git diff  d7467df

but it also show me the modified content for each file, which makes the entire thing long. I only want to see the list files that has been changed, and no contents associated. How do I achieve this?

1
  • git diff d7467df^ d7467df --name-only
    – ElpieKay
    Jul 29, 2016 at 6:41

2 Answers 2

3

git show --name-only commit_hash

1
  • Does the same thing: git log -1 --name-only commit_hash Jul 29, 2016 at 6:40
0

To cleanly list only the modified files, with no superfluous information:

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.