Ever since installing Snow Leopard on my machine, I’ve had problems using some of the commands with the Git bundle on Textmate. One of the more annoying ones was with ‘Pull’, whereby it would spit out some error message along the lines of…
/Library/Application Support/TextMate/Bundles/Git.tmbundle/Support/tmvc/lib/ruby_tm_helpers.rb:70:in `basename': can't convert nil into String
plus a whole load of other junk.
As far as I could tell, it would actually perform the ‘git pull’, but would return an error when finishing up. Busy as ever, not having time to investigate the issue, I just ignored this for a while, as it did seem to do what it was meant to.
Not ever wanting just to let errors be, and now with a bit of idle time during the Christmas break, I thought I’d get to the bottom of it. The fix is actually really rather simple. Looking at the file that is reporting the error, we see a call for ENV['TM_APP_PATH']. All we need to do to fix this error is to define TM_APP_PATH in Textmate > Preferences > Advanced> Shell Variables. So in the ‘Variable’ column, we put
TM_APP_PATH
and in the ‘Value’ column, we put in the path to your Textmate Application, which in my case is
/Applications/Textmate
.
Done!
Mike Benner — December 24, 2009
I had similar problems and also got bit by the java update that came out affecting git in RubyMine.