It creates a static wrapper that textmate will use when it runs Ruby. However, different projects have different .rvmrc's. Also, textmate can run bash script stuff just fine. So why not just have a textmate wrapper that ships with RVM that does something like:
source ~/.rvm/scripts/rvm
exec ruby "$@"
Trying it on my box, this seems to use textmate with the default configured rvm gemset.
However, what would be awesome is if it looked through the current directory hierarchy and tried to find a .rvmrc file up the ladder. If so, it can just source it directly
source ~/.rvm/scripts/rvm
#TODO: fancy bash stuff to look for the .rvmrc
# if it finds it, source the .rvmrc file right here
exec ruby "$@"
I don't know how to do the fancy bash stuff, but when I hard coded it and sourced the .rvmrc file for the project, it ran great in textmate. So looks like the trick is just to find the file path of the .rvmrc and Textmate will now be rvmrc enabled!
If you have RVM sourced already then no fancy bash stuff is required,
you only have to put this here:
cd .