title: How do I change the Ruby version Textmate uses?
body: <p>EDIT: I found a solution for this, you can read it in my answer bellow.</p>
  
  <p>I am using Textmate on Snow Leopard, and have installed ruby 1.9. The problem is that for some reason Textmate uses Ruby 1.8.2</p>
  
  <p>But when I use IRB, or run ruby scripts for the shell, the proper version of Ruby (1.9) is used.</p>
  
  <p>How can I configure Textmate so it uses 1.9.2?</p>
  
  <p>I've been googling and apparently you have to use the T_RUBY variable and textmate, and set some environment variable in OSX, but so far none of the methods I've found works for me.</p>
  
  <p>Could someone give a step by step solution to this problem?</p>
  
  <p>Update: I already tried adding the ruby binary path to TM_RUBY in textmate, and I get this error: </p>
  
  <pre><code>&gt; Can't find
  &gt; “/Users/myname/.rvm/rubies/ruby-1.9.2-p180/bin/ruby
  &gt; /Users/myname/.rvm/rubies/ruby-1.9.2-p180/bin/ruby
  &gt; /Users/myname/.rvm/rubies/ruby-1.9.2-p180/bin/ruby
  &gt; ” on PATH. Theme: The current PATH is:
  &gt; /usr/bin /bin /usr/sbin /sbin Please
  &gt; add the directory containing
  &gt; “/Users/myname/.rvm/rubies/ruby-1.9.2-p180/bin/ruby
  &gt; /Users/myname/.rvm/rubies/ruby-1.9.2-p180/bin/ruby
  &gt; /Users/myname/.rvm/rubies/ruby-1.9.2-p180/bin/ruby
  &gt; ” to PATH in TextMate's Shell
  &gt; Variables preferences.
  </code></pre>