Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to get the last person who modified a file in Git? [duplicate]

Tags:

git

Can I find out who modified given file last?

Can I also find out a list of changesets which affected a given file?

like image 588
Roman Avatar asked Sep 10 '14 16:09

Roman


2 Answers

This command should give you all the commits that changed this file with the diff. You can also see who made this commit.

git log -p <filepath>
like image 165
usha Avatar answered Sep 22 '22 20:09

usha


Try git log:

git log -n 1 -- path/to/file.html

-n 1 makes it only load the lastest commit.

like image 38
Simon Farshid Avatar answered Sep 22 '22 20:09

Simon Farshid