From: Rick DeNatale Date: 2010-09-22T20:40:54+09:00 Subject: Re: Can't load gem On Wed, Sep 22, 2010 at 5:46 AM, Jule Nissen wrote: > Jule Nissen wrote: >> Hi! >> >> I've run into some trouble while updating my ruby-version on ubuntu. >> I installed ruby1.9.1 linked /usr/bin/ruby to ruby1.9.1 >> installed rubygems1.3.7 with ruby1.9.1. > when I run > > irb(main):001:0> require 'ri_cal' > > I get this error: > > LoadError: no such file to load -- ri_cal >  from (irb):1:in `require' >  from (irb):1 >  from /usr/bin/irb:12:in `
' > irb(main):002:0> > > with require gems its like this: > > > irb(main):001:0> require 'rubygems' > => true > irb(main):002:0> require 'ri_cal' > LoadError: no such file to load -- ri_cal >  from (irb):2:in `require' >  from (irb):2 >  from /usr/bin/irb:12:in `
' > irb(main):003:0> > > > >> >> My gem env output is this: >> >> RubyGems Environment: >>   - RUBYGEMS VERSION: 1.3.7 >>   - RUBY VERSION: 1.9.1 (2010-01-10 patchlevel 378) [i486-linux] >>   - INSTALLATION DIRECTORY: /usr/lib/ruby/gems/1.9.1 >>   - RUBY EXECUTABLE: /usr/bin/ruby1.9.1 >>   - EXECUTABLE DIRECTORY: /usr/bin >>   - RUBYGEMS PLATFORMS: >>     - ruby >>     - x86-linux >>   - GEM PATHS: >>      - /usr/lib/ruby/gems/1.9.1 >>      - /home/jule/.gem/ruby/1.9.1 >>   - GEM CONFIGURATION: >>      - :update_sources => true >>      - :verbose => true >>      - :benchmark => false >>      - :backtrace => false >>      - :bulk_threshold => 1000 >>   - REMOTE SOURCES: >>      - http://rubygems.org/ >> >> When I run >> >>> ruby --disable-gems -S irb >>> require 'rubygems' >>> require 'ri_cal' >> >> everything works fine! >> >> Does ruby load a wrong gem version by default? >> How is it possible to configure this? >> Is it an ruby or an ubuntu issue? >> >> Really don't know how to find a solution. >> >> Thanks in advance. >> >> landge >> >> PS: I haven't set any environment variables > Have you installed the ri_cal gem under 1.9? there are separate gem directories for 1.8 and 1.9. Probably not the problem but Ruby 1.9.1 is getting rather old, but I guess that's the latest debian/ubuntu packaged version of Ruby. -- Rick DeNatale Blog: http://talklikeaduck.denhaven2.com/ Github: http://github.com/rubyredrick Twitter: @RickDeNatale WWR: http://www.workingwithrails.com/person/9021-rick-denatale LinkedIn: http://www.linkedin.com/in/rickdenatale