Setup git on windows to use kdiff3 as it’s mergetool

Posted by Konrad 'ktoso' Malawski on 26/02/2011 – 00:04;

As I’ll be leading BOTH a presentation and a workshop about git at the upcomming Academic It Festival I’m preparing myselffor the most problematic of all problems… MS Windows! Just kidding ;-) But it’s highly probable that most users will have Windows installed on their notebooks so I’ll better be prepared :-) One of the things woth using for merges is… the mergetool. My favourite (besides intellij) is KDiff3 it really rocks and usability and look and feel are on a very high standard.

As I’d rather show the participants around git and not just “how the hell do I use vimdiff?!” I’m posting this little snippet on howto use KDiff3 on windows. Of course we’re probably going to have quite simple conflicts that could easily be conflicted without tooling but it’s nice to have one prepared when you need one. So, this is what you need to run KDiff3 on windows as a mergetool (paste this inside of your .git/config file)

    tool = kdiff3

[mergetool "kdiff3"]
    path = C:/Program Files/KDiff3/kdiff3.exe
    keepBackup = false
    trustExitCode = false

And you’ll need to download kdiff3 for windows of course, this can be done on their sourceforga page. And that’s basically it. I’ll reconfirm that this really works tomorrow as I’m getting somewhat tired already… Well then…

Gundam fighters set, ready….. goooo!
* stupid quote from  G Gundam ;-)

Tags: , , , , , , , ,

This post is under “coding, english, guide” and has 2 respond so far.

2 Responds so far- Add one»

  1. 1. David Said:

    Thanks for this! Best instructions for this that I’ve found, and added link in StackOverflow thread on the subject:

    Meanwhile, hope your presentation went well. ;)

  2. 2. kalibbala Said:

    thks man u saved my Ass

Post a reply