Updating Ruby / Rails

August 30, 2009

Updating Ruby, Rails and other installed gems is pretty easy.

1 – Run the command “gem outdated”, to see which of your installed gems need updating.

2 – Update the gems itself by running

gem update --system

3 – Then if you want to update all the gems, simply run the command “gem update”. If you’re running the command in Windows, you should probably run “gem update > result.txt”, which will output the results of the command in the text file, so that you can take a look if any error were reported in the process.

4 – Finally, if you made an update of Rails, you will need to manually change the version your project uses by going into config/environment.rb and finding and changing this line:

RAILS_GEM_VERSION = '2.3.3' unless defined? RAILS_GEM_VERSION

Entry Filed under: Uncategorized. Tags: , , .

2 Comments Add your own

  • 1. Marcelo  |  August 31, 2009 at 2:30 pm

    Hi! Is it recommended to run these commands as a super-user (sudo)? I think I did both ways in the past, by mistake.

    But everything is working, by the way.

    Reply
  • 2. allaboutruby  |  August 31, 2009 at 7:27 pm

    I don’t have that much experience with doing Unix installs, but sudo should work fine

    Reply

Leave a Comment

Required

Required, hidden

Some HTML allowed:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <pre> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Trackback this post  |  Subscribe to the comments via RSS Feed


Recent posts

Starting to learn Rails?

Archive

Recent comments

allaboutruby on Installing Rails on Windows (3…
Opennyimparne on Installing Rails on Windows (s…
Ryan H on Installing Rails on Windows (3…
gogetakame on Installing Rails on Windows (3…
gogetakame on Installing Rails on Windows (3…