# Where's Ruby? Too many Ruby interpreters on OS X

**URL:** <https://www.ruby-forum.com/t/wheres-ruby-too-many-ruby-interpreters-on-os-x/61371>\
**Category:** Rails\
**Created:** [May 23, 2006, 3:50pm UTC](https://www.ruby-forum.com/t/wheres-ruby-too-many-ruby-interpreters-on-os-x/61371 "2006-05-23T15:50:28Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Bill\_EdstromS\_Jr](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/848f3c/32.png) [@Bill\_EdstromS\_Jr](https://www.ruby-forum.com/u/Bill_EdstromS_Jr)\
**Post date:** [May 23, 2006, 3:50pm UTC](https://www.ruby-forum.com/t/wheres-ruby-too-many-ruby-interpreters-on-os-x/61371/1 "2006-05-23T15:50:28Z")

</div>

I seem to have two versions of Ruby on my PowerBook. I have been  
learning  
RoR and walked through the online scripted install of Ruby and Rails  
several  
weeks ago before I really understood what was going on.

If I open Terminal and type:

ruby -v

I get back:

ruby 1.8.4 (2005-12-24) [powerpc-darwin8.5.0]

So that looks fine, but I don’t know where my Ruby interpreter is  
located. I  
realize this when I downloaded and installed the Komodo IDE over the  
weekend. When Komodo loads a Ruby I get backs:

Ruby 1.8.2 [powerpc-darwin8.0]

> 

I think this is the default OS X ruby interpreter. In the Komodo  
Preferences  
I found that Komodo is pointing to /usr/bin/ruby for it’s interpreter. I  
thought this was where my Rails programs were going for Ruby but that is  
clearly not the case.

I don’t want to have more than one version of Ruby. I know the source  
files  
for the version that I installed myself are located at

I know my source files are located under my home directory at /src/ruby-  
1.8.4. Where should I look for my working Ruby install?

---

<div class="post-metadata">

**Author:** ![Bill\_EdstromS\_Jr](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/848f3c/32.png) [@Bill\_EdstromS\_Jr](https://www.ruby-forum.com/u/Bill_EdstromS_Jr)\
**Post date:** [May 23, 2006, 3:53pm UTC](https://www.ruby-forum.com/t/wheres-ruby-too-many-ruby-interpreters-on-os-x/61371/2 "2006-05-23T15:53:50Z")

</div>

On 5/23/06, Bill Edstrom, Jr. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> > ruby 1.8.4 (2005-12-24) [powerpc-darwin8.5.0]  
> > …
> 
> I know my source files are located under my home directory at  
> /src/ruby-1.8.4 . Where should I look for my working Ruby install?

Type:

which ruby

in the terminal to see where the version of Ruby that is the default is  
located.

jt

---

<div class="post-metadata">

**Author:** ![Bill\_EdstromS\_Jr](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/848f3c/32.png) [@Bill\_EdstromS\_Jr](https://www.ruby-forum.com/u/Bill_EdstromS_Jr)\
**Post date:** [May 23, 2006, 4:42pm UTC](https://www.ruby-forum.com/t/wheres-ruby-too-many-ruby-interpreters-on-os-x/61371/3 "2006-05-23T16:42:01Z")

</div>

Bill Edstrom, Jr. wrote:

> I seem to have two versions of Ruby on my PowerBook. I have been  
> learning  
> RoR and walked through the online scripted install of Ruby and Rails  
> several  
> weeks ago before I really understood what was going on.

If it’s the walkthrough I think it is, you installed 1.8.4 in /usr/local  
and put /usr/local/bin first in your path. This means from the shell,  
you get /usr/local/bin/ruby (which is 1.8.4). If Komodo is hardcoded  
to point to /usr/bin (instead of using the path) it’ll get 1.8.2.

You can run which ruby from the shell to confirm my thinking 🙂

If you can configure Komodo and tell it to use a different Ruby, do that  
(/usr/local/bin/ruby).

If you can’t, or maybe even if you can’t, I also rm /usr/bin/ruby and  
create a symlink there to /usr/local/bin/ruby, just to be sure, but  
YMMV.

cd /usr/bin

sudo mv ruby ruby.old  
sudo mv ri ri.old  
sudo mv irb irb.old  
sudo mv rdoc rdoc.old

sudo ln -s /usr/local/bin/ruby  
sudo ln -s /usr/local/bin/ri  
sudo ln -s /usr/local/bin/irb  
sudo ln -s /usr/local/bin/rdoc

This way, if anyone hardlinks to /usr/bin, they’ll get your local  
version instead.

Alan

---

<div class="post-metadata">

**Author:** ![Bill\_EdstromS\_Jr](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/848f3c/32.png) [@Bill\_EdstromS\_Jr](https://www.ruby-forum.com/u/Bill_EdstromS_Jr)\
**Post date:** [May 23, 2006, 6:43pm UTC](https://www.ruby-forum.com/t/wheres-ruby-too-many-ruby-interpreters-on-os-x/61371/4 "2006-05-23T18:43:48Z")

</div>

> which ruby
> 
> in the terminal to see where the version of Ruby that is the default is  
> located.

Ok, typing “which ruby” give me:

/usr/local/bin/ruby

as predicted in the next email!

Making progress…!!!

---

<div class="post-metadata">

**Author:** ![Bill\_EdstromS\_Jr](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/848f3c/32.png) [@Bill\_EdstromS\_Jr](https://www.ruby-forum.com/u/Bill_EdstromS_Jr)\
**Post date:** [May 23, 2006, 6:47pm UTC](https://www.ruby-forum.com/t/wheres-ruby-too-many-ruby-interpreters-on-os-x/61371/5 "2006-05-23T18:47:06Z")

</div>

Komodo is not hard coded. I can point it to any Ruby interpreter. I was  
really just trying makes sure my development enviroment was clean.

Thanks. The RoR community and this list are Awesome!
