Setup git on windows to use kdiff3 as it’s mergetool
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)
[merge] 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 ;-)