rvm “default” version implementation

According to the official site (http://beginrescueend.com/rubies/default/), the “default” setting of rvm controls the ruby version that is loaded “when you open a new terminal shell”.

I am wondering, how exactly does rvm implement this functionality? It doesn’t seem to be via .bash_profile/.bashrc (they are unmodified).

It might be attributed to my using PuTTY on Windows logging into a Debian VPS (unlikely methinks), but whenever I open a new PuTTY login shell, the following transpires:

root:~# rvm list default

Default Ruby (for new shells)

   ruby-1.9.2-p290 [ i386 ]

root:~# rvm current
root# which ruby

That’s interesting. It managed to pick up that the default should be 1.9.2, but didn’t actually modify the rvm “current” data, nor the ruby paths?


rvm must be loaded as function, no rvm ruby must be already in PATH

most likely you have issue with the first part, read https://rvm.beginrescueend.com/support/faq/#shell_login for details, but running this most likely will help:

rvm get head --auto

Source : Link , Question Author : omnilinguist , Answer Author : mpapis

Leave a Comment