Upgrading Rubies (use RVM)

ref: https://rvm.io/rubies/upgrading/

Upgrades the specified (already installed) source ruby given to the given destination ruby version. Will migrate gemsets, wrappers, aliases and environment files.

The process will prompt you at each stage – if the versions look incorrect, please cancel and perform it manually.

Examples
$ rvm upgrade 1.9.2-p136 1.9.2-p180
$ rvm upgrade ree-2011.01 ree-2011-03

Upgrade is easy, but it does all at once, if you need to do it once at a time check out following instructions.

Copying single gemsets to new ruby

When testing another ruby distribution it is possible to simply copy gemset. Just install new ruby, copy your gemset and test if your application will past all the test you have.

Examples
$ rvm gemset copy 1.8.6-p420@myapplication rbx-1.2.3@myapplication

Manual migration of all gemsets

When there are already two versions installed of ruby, it is possible to migrate gemset from one to another. During migration gems will be copied from first to second and removed from first.

An good usecase would be installation of Rubinius or JRuby – just to test them and after being convinced that they work it is possible to migrate all gemsets (applications) to the new ruby of choice.

Examples
$ rvm migrate 1.8.6-p420 rbx-1.2.3

Updating all gemsets

An useful option for those leaving on edge. To keep all the installed gems current it is enough to userubygems update, it will take care of updating everything.

Examples
$ rvm gemset update
Share and Enjoy:
  • Print
  • Digg
  • StumbleUpon
  • del.icio.us
  • Facebook
  • Yahoo! Buzz
  • Twitter
  • Google Bookmarks
  • MySpace
  • Plurk
  • RSS
  • Google Buzz
  • Live
本篇發表於 ROR (Ruby on Rails), Ruby, RVM。將永久鏈結加入書籤。

發表迴響

你的電子郵件位址並不會被公開。 必要欄位標記為 *