I was trying to update Rails and I ran gem install rails from my home directory and I now have a .gem directory in my home dir.
I eventually was able to update Rails properly, and deleted the .gem folder, but I now have this extra PATH in my GEM PATHS that I wanted to get rid of:
- GEM PATHS:
- /Library/Ruby/Gems/1.8
- /Users/homedir/.gem/ruby/1.8
- /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/gems/
How do I remove this? What is the “proper” way to remove this line? I haven’t the foggiest idea. Running OS X 10.6.4, Ruby 1.8.7, Gem 1.3.7, and Rails 3.0.0.
I’m pretty new at this.
The “original gem path information” is set in rubygems source themselves.
I also wanted to do it, and haven’t found a way… Then I looked for in rubygems source (at github.com) and learned that it tries to get the path from etc/gemrc and ~/.gemrc. If it fails (and fails GEM_PATH environment variable too), it assumes ~/.gem… to be the default path.
Therefore, you have either to export GEM_PATH or to create a ~/.gemrc.
Hope to have cleared things a bit!