# Which version do I have then?

**URL:** <https://rubytalk.org/t/which-version-do-i-have-then/44302>\
**Category:** ruby-talk\
**Created:** [6 February 2008 04:21 UTC](https://rubytalk.org/t/which-version-do-i-have-then/44302 "2008-02-06T04:21:25Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Sebastian\_Komianos](https://avatars.discourse-cdn.com/v4/letter/s/5e9695/32.png) [@Sebastian\_Komianos](https://rubytalk.org/u/Sebastian_Komianos)\
**Post date:** [6 February 2008 04:21 UTC](https://rubytalk.org/t/which-version-do-i-have-then/44302/1 "2008-02-06T04:21:25Z")

</div>

Hello there!

After reading the first half of Chris Pine's online tutorial I decided  
to buy the book and here I am, preparing my MacBook Pro for my serious  
studying which I plan to begin in a few hours.

However, since I am want everything to be up to date, I decided to  
update to Ruby 1.9.0 (I previously had 1.8.1). Following this  
([http://hivelogic.com/articles/ruby-rails-mongrel-mysql-osx/](http://hivelogic.com/articles/ruby-rails-mongrel-mysql-osx/)) I think I  
managed to do something, because when I type "ruby -v" on my terminal  
I...sometimes take this as the result: ruby 1.9.0 (2007-12-25 revision  
14709) [i686-darwin8.11.1]

The "sometimes" goes for the fact that the above only happens when my  
folder is "/usr/local/src/ruby-1.9.0". When I am at "/usr/local/src/" or  
below, I get this: ruby 1.8.1 (2003-12-25) [i686-darwin]. Which is quite  
confusing to me, since it looks like I have both version.

Anyways, I have never had any previous experience with language building  
or something relevant so I would really appreciate it if you can tell me  
either how to update Ruby or that it doesn't really matter if I have a  
previous version. 😛

Thanks in advance!

> **···**
>
> --  
> Posted via [http://www.ruby-forum.com/](http://www.ruby-forum.com/).

---

<div class="post-metadata">

**Author:** ![Gavin\_Kistner3](https://avatars.discourse-cdn.com/v4/letter/g/dfb087/32.png) [@Gavin\_Kistner3](https://rubytalk.org/u/Gavin_Kistner3)\
**Post date:** [6 February 2008 04:49 UTC](https://rubytalk.org/t/which-version-do-i-have-then/44302/2 "2008-02-06T04:49:56Z")

</div>

You may have a variety of binaries installed with the same name, in  
different directories. Which version you are using depends on which  
binary is 'found' first.

Search for information on the PATH environment variable to understand  
how \*nix systems resolve the binaries. If you have further questions,  
feel free to post again.

I personally have the built-in Ruby Leopard install in /usr/bin/ruby,  
my own 1.8.6-p111 build in /usr/local/bin/ruby, and another 1.9 built  
as ruby190.

> **···**
>
> On Feb 5, 9:21 pm, Sebastian Komianos \<seb...@grubies.gr\> wrote:
> 
> > Hello there!
> > 
> > After reading the first half of Chris Pine's online tutorial I decided  
> > to buy the book and here I am, preparing my MacBook Pro for my serious  
> > studying which I plan to begin in a few hours.
> > 
> > However, since I am want everything to be up to date, I decided to  
> > update to Ruby 1.9.0 (I previously had 1.8.1). Following this  
> > ([Dan Benjamin](http://hivelogic.com/articles/ruby-rails-mongrel-mysql-osx/%5C)) I think I  
> > managed to do something, because when I type "ruby -v" on my terminal  
> > I...sometimes take this as the result: ruby 1.9.0 (2007-12-25 revision  
> > 14709) [i686-darwin8.11.1]
> > 
> > The "sometimes" goes for the fact that the above only happens when my  
> > folder is "/usr/local/src/ruby-1.9.0". When I am at "/usr/local/src/" or  
> > below, I get this: ruby 1.8.1 (2003-12-25) [i686-darwin]. Which is quite  
> > confusing to me, since it looks like I have both version.
> > 
> > Anyways, I have never had any previous experience with language building  
> > or something relevant so I would really appreciate it if you can tell me  
> > either how to update Ruby or that it doesn't really matter if I have a  
> > previous version. 😛

---

<div class="post-metadata">

**Author:** ![Sebastian\_Komianos](https://avatars.discourse-cdn.com/v4/letter/s/5e9695/32.png) [@Sebastian\_Komianos](https://rubytalk.org/u/Sebastian_Komianos)\
**Post date:** [6 February 2008 05:22 UTC](https://rubytalk.org/t/which-version-do-i-have-then/44302/3 "2008-02-06T05:22:28Z")

</div>

Gavin Kistner wrote:

> Search for information on the PATH environment variable to understand  
> how \*nix systems resolve the binaries. If you have further questions,  
> feel free to post again.

Sorry but I have no idea on how I am supposed to do this.

> I personally have the built-in Ruby Leopard install in /usr/bin/ruby,  
> my own 1.8.6-p111 build in /usr/local/bin/ruby, and another 1.9 built  
> as ruby190.

Isn't there an (easy) way I remove any prior to 1.9.0 builts?

Apart from that, am I harming my Mac with all these experiments? It's  
just that I can't resist! 😃

(Hope I am not "rubbishing" your emails with my newbish questions)

> **···**
>
> --  
> Posted via [http://www.ruby-forum.com/\](http://www.ruby-forum.com/%5C).

---

<div class="post-metadata">

**Author:** ![Tim\_Hunter4](https://avatars.discourse-cdn.com/v4/letter/t/ea5d25/32.png) [@Tim\_Hunter4](https://rubytalk.org/u/Tim_Hunter4)\
**Post date:** [6 February 2008 12:39 UTC](https://rubytalk.org/t/which-version-do-i-have-then/44302/4 "2008-02-06T12:39:10Z")

</div>

Sebastian Komianos wrote:

> Gavin Kistner wrote:
> 
> > Search for information on the PATH environment variable to understand  
> > how \*nix systems resolve the binaries. If you have further questions,  
> > feel free to post again.
> 
> Sorry but I have no idea on how I am supposed to do this.
> 
> > I personally have the built-in Ruby Leopard install in /usr/bin/ruby,  
> > my own 1.8.6-p111 build in /usr/local/bin/ruby, and another 1.9 built  
> > as ruby190.
> 
> Isn't there an (easy) way I remove any prior to 1.9.0 builts?
> 
> Apart from that, am I harming my Mac with all these experiments? It's just that I can't resist! 😃
> 
> (Hope I am not "rubbishing" your emails with my newbish questions)

My advice? Remove 1.9.0 and just use the Ruby 1.8.6 that is already installed on your system. 1.9.0 is not "up to date," it's a developer's version of Ruby that has bugs and undocumented features. All the books you'll buy, and 99% of the web sites, describe 1.8.6, not 1.9.0, so all you'll do is confuse yourself. Dump 1.9.0 until you're a Ruby expert.

Also, buy a book about OS X that describes how to use the shell and Unix commands. You can't use Ruby effectively on OS X by clicking on things.

> **···**
>
> --  
> RMagick: [http://rmagick.rubyforge.org/](http://rmagick.rubyforge.org/)  
> RMagick 2: [http://rmagick.rubyforge.org/rmagick2.html](http://rmagick.rubyforge.org/rmagick2.html)
