Home > Uncategorized > Configuring Diffmerge for Git

Configuring Diffmerge for Git

One thing that I do particulary _not_ like about Git is that it doesn’t integrate with mergetools automatically. Mercurial is a bit smarter here – if you have a merge tool installed, it will find and configure it for you. With git, you have to resort to the following commands to setup diffmerge:

 

git config –global diff.tool diffmerge
git config –global difftool.diffmerge.cmd “C:\Program Files\SourceGear\Common\DiffMerge\sgdm.exe \$LOCAL \$REMOTE”

git config –global merge.tool diffmerge
git config –global mergetool.diffmerge.cmd “C:\Program Files\SourceGear\Common\DiffMerge\sgdm.exe –merge –result=\$MERGED \$LOCAL \$BASE \$REMOTE”
git config –global mergetool.diffmerge.trustExitCode true

Categories: Uncategorized
  1. No comments yet.
  1. No trackbacks yet.

Leave a comment