in Git by
Q:
How do you find a list of files that have changed in a particular commit?

1 Answer

0 votes
by
git diff-tree -r {hash}

Given the commit hash, this will list all the files that were changed or added in that commit. The -r flag makes the command list individual files, rather than collapsing them into root directory names only.

The output will also include some extra information, which can be easily suppressed by including a couple of flags:

git diff-tree --no-commit-id --name-only -r {hash}

Here –no-commit-id will suppress the commit hashes from appearing in the output, and –name-only will only print the file names, instead of their paths.
Click here to read more about GIT
Click here to read more about Insurance

Related questions

0 votes
asked Oct 16, 2019 in Git by rajeshsharma
0 votes
asked Feb 7 in Git by SakshiSharma
0 votes
asked Feb 7 in Git by SakshiSharma
0 votes
asked Feb 17, 2020 in Git by SakshiSharma
0 votes
asked Nov 11, 2020 in Linux by sharadyadav1986
...