"The editor used to edit the commit log message will be chosen from
the GIT_EDITOR environment variable, the core.editor configuration
variable, the VISUAL environment variable, or the EDITOR environment
variable (in that order)."
http://www.kernel.org/pub/software/scm/git/docs/git-commit.html
I set EDITOR to "/usr/bin/mate -w" and this seems to take care of most
applications that want to fire up a text editor.
# .bashrc
export EDITOR="/usr/bin/mate -w"
# .cshrc
setenv EDITOR "/usr/bin/mate -w"
If you don't already have the command-line "mate" command installed,
you can go to Help -> Terminal Usage in TextMate to install it.
You can also pipe other output to mate, such as
git diff | mate
Geoffrey Grosenbach
http://peepcode.com