[/Users/Ric/workarea/rails/demo/config]sudo gem update --system
Password:
Updating RubyGems
Nothing to update
I attempted to update rubygems, even though I don't need to:
[/Users/Ric/workarea/rails/demo/config]sudo update_rubygems
sudo: unable to execute /opt/local/bin/update_rubygems: No such file
or directory
But I found it here:
[/usr/bin]ls -l update_rubygems
-rwxr-xr-x 1 root wheel 462 Aug 25 15:02 update_rubygems*
But if I use 'sudo', it looks for 'update_rubygems' here:
[/usr/bin]sudo update_rubygems
sudo: unable to execute /opt/local/bin/update_rubygems: No such file
or directory
2) Why?
sudo cleans the environment up before it runs so may end up with a
different $PATH.
4) Huh?
As you can see, I have <apparently> the latest Ruby, Rails & Gem
already installed & running.
Is there some sort environment setup that I'm missing?
I think you have two ruby installations: a ruby 1.8.6 installation
that came with os x. that version of ruby has the rails gem installed,
and running rails -v finds a /usr/bin/rails installed by ruby 1.8.6.
You have since installed ruby 1.9.1, and ruby invokes that. That ruby
install does not have the rails gem installed.
you could verify this by playing with gem list (and looking at the
difference between /usr/bin/gem list and /opt/local/bin/gem list )