How do I find the most recent git commit that modified a file?

I want to find the most recent commit that modified a source file.

I can use git blame to see all the dates for commits by each line, but it’s difficult to see exactly which commit was the last one to touch the file.

How can I find the last commit that touched a given file in my git repository?

6 Answers
6

Leave a Comment