title: How do I get git to use Textmate as my default editor?
body: <p>At the command-line, if I do <code>mate &lt;filepath&gt;</code> it opens up the right file for me in TextMate.</p>
  
  <p>But when I do:</p>
  
  <pre><code>$ mate -v
  open: invalid option -- v
  Usage: open [-e] [-t] [-f] [-W] [-R] [-n] [-g] [-h] [-b &lt;bundle identifier&gt;] [-a &lt;application&gt;] [filenames] [--args arguments]
  </code></pre>
  
  <p>Also, when I do <code>git commit</code>, I see this:</p>
  
  <pre><code>$ git commit
  error: cannot run mate: No such file or directory
  error: There was a problem with the editor 'mate'.
  Please supply the message using either -m or -F option.
  </code></pre>
  
  <p>My <code>~/.bashprofile</code> has these lines:</p>
  
  <pre><code>#Set Textmate as my default editor from the command-line
  alias mate='open -a TextMate.app'
  
  export EDITOR="/usr/local/bin/mate -w"
  </code></pre>
  
  <p>And <code>~/.bashrc</code> has just this one:</p>
  
  <pre><code>alias mate='open -a TextMate.app'
  </code></pre>
  
  <p><strong>Edit 1</strong></p>
  
  <p>My <code>~/.gitconfig</code> includes the following:</p>
  
  <pre><code>[user]
      name = My Name
      email = myemail@address.com
  [core]
      editor = mate
  [github]
      user = marcamillion
      token = 50e3iuaidsgadjkhwkjegakjhbsdkjb30432 (don't worry, this is fake)
  </code></pre>
  
  <p>Help!</p>