Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I upgrade my ruby 1.9.2-p0 to the latest patch level using rvm?

My current version of ruby is ruby 1.9.2p0 (2010-08-18 revision 29036) [x86_64-darwin10.5.0] but I want to update it to the latest patch level using rvm. How can I do this?

like image 682
Lan Avatar asked Jan 01 '11 14:01

Lan


People also ask

How do I update RVM?

First of all, update your RVM installation by running rvm get stable . To make sure you're running the new RVM version, you'll then need to run rvm reload (or just open a new terminal). Once that's done, you can ask RVM to list the ruby versions available to install by running rvm list known .

How do I change the default version of ruby in RVM?

Try running rvm --default 1.9. 2 instead. That works for me. Did you accidentally put the line to load rvm in your bashrc instead of your bash_profile ?


1 Answers

First of all, update your RVM installation by running rvm get stable.

To make sure you're running the new RVM version, you'll then need to run rvm reload (or just open a new terminal).

Once that's done, you can ask RVM to list the ruby versions available to install by running rvm list known.

In the output you should now see:

# MRI Rubies ... [ruby-]1.9.2[-p320] ... 

The square brackets around the patch level indicate that this is currently RVM's default patch level for ruby 1.9.2.

Finally, to install the new ruby version, just run rvm install 1.9.2 - and wait for it to compile!

like image 71
npad Avatar answered Sep 21 '22 13:09

npad