git diff <commitA> --name-only

Show the names of the changed files between the current commit and specific commit

This command shows the names of the files that have been changed between the current commit and commitA. It provides a summary of the changes without displaying the actual content of the files.

<commitA> is the specific commit you want to compare to the current commit. By using the --name-only flag, it tells git to only display the names of the changed files. This can be useful when you just need a quick overview of the modifications without the need for a detailed diff.

Some possible variations include:

  • git diff <commitA> <commitB> --name-only: This command can be used to show the names of the changed files between commitA and commitB. By specifying two commits, you can compare a specific range of commits.
  • git diff --stat <commitA>: By using the --stat flag instead, Git provides a summary of the modifications including the number of changed lines for each file.
Specific examples:
git commit f8da76c --name-only