Created
November 30, 2010 19:51
-
-
Save anonymous/722271 to your computer and use it in GitHub Desktop.
p4merge script for Windows; to be placed in C:\Program Files(x86)\Git\bin (MSYS Git)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
NULL=$TMP/$$.NULL | |
for arg; do [[ $arg = /dev/null ]] && arg=$NULL && echo "" >"$arg"; args+=("$arg"); done; | |
/c/Program\ Files/Perforce/p4merge "${args[@]}" | |
[[ -f $NULL ]] && rm $NULL |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The
echo "" >"$arg"
adds an unnecessary (and annoying) empty line to the temporary file. I usetouch "$arg"
instead.