Oin
Oin

Reputation: 7539

How can I see the list of differing commits on one file between two branches?

Is there any way to do this in git? Just see a list of the differing commits between two branches, I can't just look at the logs, because there have been dozens of different commits over several months to the two branches.

Upvotes: 1

Views: 73

Answers (3)

Tobi
Tobi

Reputation: 81813

Play with the options --left-right and --cherry-pick to git log.

And specify the file name, as mentioned by Michael Krelin and knittl.

Upvotes: 1

knittl
knittl

Reputation: 265845

Use a filespec when invoking git log:

git log commit1 commit2 -- file1 file2

Upvotes: 2

Michael Krelin - hacker
Michael Krelin - hacker

Reputation: 143269

Try specifying path to git log?

Upvotes: -1

Related Questions