If you like meld for comparing files and resolving merges, you should probably set the config options diff.tool
and merge.tool
to meld
, e.g.
git config diff.tool meld
You can then use git difftool master origin/master
to view the differences between your local master
and the most recently fetched version of master
from origin
. However, that will only show the differences one file at a time - you have to exit meld and hit enter to see the changes in the next file. If you'd like to see all the differences between two branches in meld, using its recursive view, there's not a one-line way of doing that, I'm afraid.
However, I wrote a short script in answer to a very similar question that takes two refs (e.g. two branches), unpacks them to temporary directories and runs meld to compare the two:
Anyway, if you've just run git fetch
you can compare the differences between your master
and the version from origin
using that script with:
meld-compare-refs.py master origin/master
... or compare two local branches with:
meld-compare-refs.py master topic1