Skip to content

Instantly share code, notes, and snippets.

@smac89
Last active June 21, 2017 15:59
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save smac89/0288f96330e1ae7470e3a7fdfa03d151 to your computer and use it in GitHub Desktop.
Save smac89/0288f96330e1ae7470e3a7fdfa03d151 to your computer and use it in GitHub Desktop.
Gitconfig settings to use p4merge on windows using Cygwin terminal
[merge]
tool = p4merge
[mergetool "p4merge"]
path = "C:/PROGRA~1/Perforce/p4merge.exe"
[mergetool]
keepBackup = false
trustExitcode = false
[diff]
tool = p4merge
[difftool "p4merge"]
cmd = "C:/PROGRA~1/Perforce/p4merge.exe `cygpath -asm $LOCAL` `cygpath -asm $REMOTE`"
[difftool]
prompt = false
@smac89
Copy link
Author

smac89 commented Apr 26, 2016

You can create the short name for the location of p4merge by running the following command from cygwin terminal:
cygpath.exe -asm /cygdrive/c/Program\ Files/Perforce/p4merge.exe

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