Forum: Ruby Best way to upgrade from 1.8.2 to 1.8.4 on Linux?

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
9bf401eea2766b0e6d65516c1601d71f?d=identicon&s=25 unknown (Guest)
on 2005-12-20 03:14
(Received via mailing list)
I have installed from source Ruby in the folder /usr/lib/ruby-1.8.2/.
(I use Linux)
If I do "which ruby" I get /usr/local/bin/ruby. It seems that Ruby has
created the folder /usr/local/bin and filled it with ruby, irb, etc...
I don't mind, this is all fine.

Now my question is: when at XMAS Metz dressed like Santa will bring me
Ruby 1.8.4, how should I upgrade?

I was thinking do to the following:
1) Remove the folder /usr/lib/ruuby-1.8.2/
2) Install Ruby 1.8.4 from source in /usr/lib/ruby-1.8.4/
3) During the Installation of Ruby 1.8.4, it will overwrite
automatically the folder /usr/local/bin/ with the new versions of ruby,
irb, etc... I am not sure if it works automatically in this way. Can
you confirm?
If it doesn't happen out-of-the-box, I was thinking to create a
symbolic link from /usr/local/bin to /usr/lib/ruby-1.8.4/bin/.

Regarding Gem and Rails, I will probably just remove Gem's folder and
reinstall it. And then just reinstall the main gems that I am using
including Rails. The rails websites/application that I have done are
saved elsewhere and shouldn't be affected.

Is it a good approach? How will you do it?
Fe9b2d0628c0943af374b2fe5b320a82?d=identicon&s=25 Eero Saynatkari (rue)
on 2005-12-20 04:07
unknown wrote:
> I have installed from source Ruby in the folder /usr/lib/ruby-1.8.2/.
> (I use Linux)
> If I do "which ruby" I get /usr/local/bin/ruby. It seems that Ruby has
> created the folder /usr/local/bin and filled it with ruby, irb, etc...
> I don't mind, this is all fine.
>
> Now my question is: when at XMAS Metz dressed like Santa will bring me
> Ruby 1.8.4, how should I upgrade?
>
> I was thinking do to the following:
> 1) Remove the folder /usr/lib/ruuby-1.8.2/
> 2) Install Ruby 1.8.4 from source in /usr/lib/ruby-1.8.4/
> 3) During the Installation of Ruby 1.8.4, it will overwrite
> automatically the folder /usr/local/bin/ with the new versions of ruby,
> irb, etc... I am not sure if it works automatically in this way. Can
> you confirm?
> If it doesn't happen out-of-the-box, I was thinking to create a
> symbolic link from /usr/local/bin to /usr/lib/ruby-1.8.4/bin/.
>
> Regarding Gem and Rails, I will probably just remove Gem's folder and
> reinstall it. And then just reinstall the main gems that I am using
> including Rails. The rails websites/application that I have done are
> saved elsewhere and shouldn't be affected.
>
> Is it a good approach? How will you do it?

If you plan on having multiple supported installations,
it is probably best to install both packages with the
--program-suffix option and then symlink the 'real'
binary names to whichever is the default one. This
way you have access to explicit versions if you need
them.

(Remember to install 1.9 too ;)


E
This topic is locked and can not be replied to.