Wednesday, July 31, 2013

Beyond Compare with Mercurial

To get the excellent Beyond Compare to work as my graphical diff tool in Mercurial (Hg) on Windows, I needed to add the following lines to my mercurial.ini:
[extdiff]
cmd.bcomp = C:\Program Files\Beyond Compare 3\BComp.exe
opts.bcomp = /ro /solo
Then, from the commandline, I can use
hg bcomp
to get a diff of all changes in the directory, or I can specify a filename to see differences in it. Without the /ro /solo, I ran into issues with the temporary directories in a dir diff being deleted immediately before Beyond Compare got a chance to compare them. That's because without them, Hg thinks that Beyond Compare completed immediately. Those options tell Beyond Compare to hold off on telling Hg it's done until after you have manually closed Beyond Compare.

No comments:

Post a Comment