Meld Diff3

Meld provides visual diff to files and directories. Primarily it allows the user to visual view differences within files in order to merge them together. Recently I needed to merge a number of git projects on a linux machine. Git can be configured to work better with Meld by utilizing additional views within tabs.

To configure Meld to work better with git, simply edit .gitconfig and add the following:

conflictstyle = diff3
tool = meld_diff3
[mergetool "meld_diff3"]
cmd = meld -diff $LOCAL $BASE --diff $BASE $REMOTE --diff $LOCAL $BASE $REMOTE $MERGED

This will open up three tabs in Meld instead of one. The additional tabs will show the changes in the local and remote versions against the common ancestor which can be very helpful when determining where changes have taken place.

$LOCAL is the current version of the file
$REMOTE is the version of the file that is being merged in
$BASE is the common ancestor of both $LOCAL and $REMOTE
$MERGED is the final file that needs to have conflicts resolved.

Comments are closed.



  • slide
  • slide
  • slide
  • slide
Casino Canada Online