Reputation: 39671
I have two branches A, and B. (they're both remote branches too). Is there a way to do a diff of a single file between the two branches? It's located in the same place in both branches etc.
Upvotes: 1
Views: 220
Reputation: 97270
git diff A:File..B:File
Git Reference (abot git diff), Git Community Book, "git - compare branches" for details
Upvotes: -1
Reputation: 12235
I use git diff branch1 branch2 -- <File1>[, <File2>...]
to achieve this.
Upvotes: 4