Using Beyond Compare for Visual Diff in TortoiseHg
-
25-09-2019 - |
Question
I am trying to use Beyond Compare for Visual Diff in TortoiseHg. eg Right click on a modified file in explorer and select Visual Diff from TortoiseHg context menu...
BeyondCompare opens but only shows the 'welcome' screen and not the file I want to diff. Am I missing something?
I have setup the mercurial.ini file as follows:
[extensions]
extdiff =
[extdiff]
cmd.bcomp = C:\Program Files (x86)\Beyond Compare 3\BCompare.exe
opts.bcomp = /ro
[tortoisehg]
vdiff = bcomp
[merge-tools]
bcomp.executable = C:\Program Files (x86)\Beyond Compare 3\BComp
bcomp.args = $local $other $base $output
bcomp.priority = 1
bcomp.premerge = True
bcomp.gui = True
[ui]
merge = bcomp
Solution
Found the answer.
Visual Diff Tool in TortoiseHg Global Settings had to be set to 'beyondcompare3' instead of 'bcomp'.
OTHER TIPS
In our case the same problem happened when we added mercurial.ini
to TortoiseHG
. It looks like by default configuration comes from TortoiseHG\hgrc.d
folder. Specifically diff and merge tools configuration can be found in MergeTools.rc
.
Just for the reference, here is how Beyond Compare 3
can be configured manually in mercurial.ini
:
[merge-tools]
bcomp.executable = C:\Program Files (x86)\Beyond Compare 3\BComp.exe
bcomp.priority = 1
bcomp.premerge = True
bcomp.gui = True
bcomp.args=$local $other $base /mergeoutput=$output /ro /lefttitle=parent1 /centertitle=base /righttitle=parent2 /outputtitle=merged /automerge /reviewconflicts /solo
bcomp.diffargs=/lro /lefttitle='$plabel1' /righttitle='$clabel' /solo /expandall $parent $child
bcomp.diff3args=$parent1 $parent2 $child /lefttitle='$plabel1' /centertitle='$clabel' /righttitle='$plabel2' /solo /ro
bcomp.dirdiff=True
Notice that there's no need in enabling extdiff
extension. Also TortoiseHG should be restarted to apply this setting.