Skip to content

Instantly share code, notes, and snippets.

@ardell
Created August 5, 2010 18:54
Show Gist options
  • Save ardell/510189 to your computer and use it in GitHub Desktop.
Save ardell/510189 to your computer and use it in GitHub Desktop.
# I put these in my ~/.zshrc, you can put them in your .git/config if you prefer (but in a different format)
git config --global merge.tool opendiff
git config --global merge.opendiff.cmd ~/git-diff-cmd.sh
git config --global mergetool.prompt false
--- My ~/git-diff-cmd.sh (make sure you "chmod +x" it!) ---
#!/bin/sh
/usr/bin/opendiff "$2" "$5" -merge "$1"
--- How to use it ---
$> git rebase master
[...]
CONFLICT
$> git mergetool
[opendiff opens]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment