DiffMerge setup with git
(Original instructions from @jeresiv)
git config --global diff.tool sgdm
git config --global difftool.sgdm.cmd 'sgdm "$LOCAL" "$REMOTE"'
git config --global merge.tool sgdm
git config --global mergetool.sgdm.cmd 'sgdm --merge --result="$MERGED" "$LOCAL" "$(if test -f "$BASE"; then echo "$BASE"; else echo "$LOCAL"; fi)" "$REMOTE"'
git config --global mergetool.sgdm.trustExitCode true
git config --global diff.tool sgdm
git config --global difftool.sgdm.cmd '/Applications/DiffMerge.app/Contents/MacOS/DiffMerge "$LOCAL" "$REMOTE"'
git config --global merge.tool sgdm
git config --global mergetool.sgdm.cmd '/Applications/DiffMerge.app/Contents/MacOS/DiffMerge --merge --result="$MERGED" "$LOCAL" "$(if test -f "$BASE"; then echo "$BASE"; else echo "$LOCAL"; fi)" "$REMOTE"'
git config --global mergetool.sgdm.trustExitCode true