I have 2 folders (with different code) with git initialized. But when I do
git difftool -t meld
one repo is working fine and asking me if I want to open files in meld to compare. The other one just output everything in the console and didn't execute meld.
Also both .git/config file is the same (except for the url)
Does anyone know why is that?
You may have configured your
diff.tool
locally instead of globally (inspect the content of.git/config
files in both your porjects, and your global~/.gitconfig
file).To set meld as your global difftool :
Is it possible you have configured
difftool
, but notmergetool
, and had a conflict outstanding?I found similar behaviour, when I had an existing conflict that needed resolving. I think what happened to me was that git was trying to be 'helpful' and launch
mergetool
when I asked fordifftool
. I had not set up anymergetool
, onlydifftool
. When I manually resolved the conflict withgit add
,difftool
started working again. Very frustrating.If in one repository you're in conflicted state (check by
git status
), you need to usemergetool
instead, e.g.Related: git difftool runs git diff.