Skip to content

Instantly share code, notes, and snippets.

@kjlubick
Last active November 2, 2023 02:49
Show Gist options
  • Save kjlubick/5a49a3ae5f39ae359997 to your computer and use it in GitHub Desktop.
Save kjlubick/5a49a3ae5f39ae359997 to your computer and use it in GitHub Desktop.
How to install Meld on Windows and getting it set up with Git
After installing it http://sourceforge.net/projects/meld-installer/
I had to tell git where it was:
git config --global merge.tool meld
git config --global diff.tool meld
git config --global mergetool.meld.path “C:\Program Files (x86)\Meld\meld\meld.exe”
And that seems to work. Both merging and diffing with “git difftool” or “git mergetool”
@leandroruel
Copy link

leandroruel commented Feb 14, 2017

Windows Help:
if someone is having errors on git bash like "bad line in .gitconfig" just make a small change in your .gitconfig file, go to C:\Users\YourComputerUserName\.gitconfig

and change the lines below
from:

[mergetool "meld"]
path = “C:\Program Files (x86)\Meld\meld\meld.exe”

to:

[mergetool "meld"]
	cmd = '\"/c/Program Files (x86)/Meld/meld/meld.exe\" $PWD/$LOCAL $PWD/$BASE $PWD/$REMOTE --output=$PWD/$MERGED'

😃

@jotadepicas
Copy link

If you are using git bash under Windows, the git config sentence fails.
I don't know how to reference directory "Program Files (x86)" properly from git bash and make it work (it has spaces, parenthesis, you name it), so I neded up re-installing meld to a more linux-friendly path like "c:\Meld" and doing a:

git config --global mergetool.meld.path '/c/Meld/meld/meld.exe

@goldtreefrog
Copy link

Try single quotes instead of double quotes. Seemed to work for me.

@d-korni
Copy link

d-korni commented Dec 1, 2017

Hi guys,

The website says that this is no longer supported due to the new builds having their own installers.
On the other side, support for windows installers in latest versions is dropped.

Can somebody confirm that this will work for the latest stable windows build?
Also, will this create a shell entry on right click, or do I need to follow some custom way?

Appreciate any help! : )

UPDATE: For any people in the future, I decided to go down a path that seemed simpler for me, and will also be easier to include updates with. I've downloaded and extracted the source code, and I have installed Python 3.4 (isn't compatible with my 3.6 version), and PyObject as suggested from the website. I've then made a batch script, and added it to my right-click mouse menu.

So rather than installing, I am running it from the source files. Updating will be as easy as replacing the source files folder and updating the script. Hope it helps some people. Cheers

@TomyLobo
Copy link

@deweysia
Copy link

deweysia commented Oct 23, 2018

This worked. Although the directory structure has changed so pay attention to the path. Thanks a lot!

@javgo
Copy link

javgo commented Jul 24, 2019

Thanks for the info!

Currently Meld is by default installed in C:\Program Files (x86)\Meld\Meld.exe so you may set it like this:

git config --global mergetool.meld.path 'C:\Program Files (x86)\Meld\Meld.exe'

@madphysicist
Copy link

I am having trouble setting this up. My errors look exactly like https://stackoverflow.com/q/58100654/2988730. It appears that GTK is not getting picked up for some reason.

@EzequielBurg
Copy link

thank you. This save me

@mangelozzi
Copy link

I added this to my path (env variable):

C:\Program Files (x86)\Meld

That way I can share my git config between windows and ubuntu (dont need to set mergetool.meld.path)

@AndreyDruzhbin
Copy link

Thank you!!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment