How to Upgrade to Ruby 1.9.2

How do I upgrade my ruby 1.9.2-p0 to the latest patch level using 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.

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!

how to upgrade rails application from ruby 1.9 to 2.0

You need to follow the following steps:

  • Install new Ruby Version
  • Run bundle install (you may need to update some gems and rails)
  • Run tests . (If you have coverage of all of you application. If not run the whole application manually and fix the errors. Most of the errors would be syntax and other small issues.)
  • Your application is migrated.

Upgrading ruby 1.8.6 to ruby 1.9.2

In Ruby a lot of us face these types of situations, where upgrading to a newer version could potentially break your code which used to work fine in an older one.

The fantastic Mr. Wayne E. Seguin faced it too, and created a great tool for solving this called rvm.

In a nutshell rvm lets you install different versions of ruby (1.8.7 or 1.9.2 for example) and easily switch between these with a simple

rvm use 1.8.7

You should go to https://rvm.io/ and learn how to install rvm on your machine. Then you can install both your current ruby version and the one you wish to upgrade to. Switch between the two and test if your scripts are working. This should at least save you some time in the future.

How to Upgrade Ruby 1.8.7 to 1.9.2 in Rubinius

Instead of deleting rubinius, I just write the command:

rvm ruby-1.9.3

then it works.

Upgrading form Ruby 1.9.2 to 1.9.3, Should I re-install all gems?

you can run

rvm upgrade 1.9.2 1.9.3

this will:

  • install latest 1.9.3 (if needed)
  • copy all gemsets
  • run gem pristine on every single gem and report those that failed
  • ask you if you want to delete the old ruby

the step with gem pristine is required as there might be changes between rubies that would break stuff - especially that gem creators use internal ruby stuff.

upgrade from ruby 1.8.7 to 1.9.2

There is way too many subtle changes to cover in something like SO, but this covers it quite well (I'm not involved in any way):

http://www.rubyinside.com/19walkthrough/

Assuming you're using fairly standard Ruby there shouldn't be anything which will cause problems, but I'm sure your tests will point out anything that needs fixing.

Ruby 1.8.7 - upgrade to 1.9.2

You're stalling. You clearly know the answers to most of your questions, you're just shaky on whether or not you're right in your assumptions.

Yes 1.9.2 is faster. Yes you probably want to use RVM (though rbenv is gaining popularity too). You probably won't have many issues with your code updating to 1.9.2, but some libraries (e.g. rubydebug) are 1.8 specific.

I would recommend you don't stick with Site5. Either run your own (cloud?) server or (and I prefer this route) go with Heroku and focus on building your app, not managing a server.



Related Topics



Leave a reply



Submit