to learn more. And ask questions here, too, if you try but cannot
figure something out.
I started playing with this and ran into a lack of PATH (I guess).
require doesn’t find the library I just installed.
ri doesn’t either, but someone mentioned gemri instead.
I started playing with this and ran into a lack of PATH (I guess).
require doesn’t find the library I just installed.
ri doesn’t either, but someone mentioned gemri instead.
I guess this puts me at step 0.0.1?
You don’t have to stumble around in the dark while waiting for some kind
soul here to guide you. RubyGems has good user doc, available from the
RubyGems project page at the link marked “Project Home Page”. Here’s the
link: http://docs.rubygems.org/. (This link is also the #1 result if you
Google for “rubygems”.)
Here’s something that a lot of newcomers miss: RubyGems is not only a
way to install Ruby libraries, it’s also the mechanism for using these
libraries after they’re installed. Look at “Chapter 3.4 Post-install –
Setting Up the RubyGems Environment” for the details.
to learn more. And ask questions here, too, if you try but cannot
figure something out.
I started playing with this and ran into a lack of PATH (I guess).
require doesn’t find the library I just installed.
ri doesn’t either, but someone mentioned gemri instead.
Does your code include
require ‘rubygems’
before you try to load files installed as gems?
You can also define that on the command line:
ruby -rubygems my_app.rb
or add it to your RUBYOPT environment variable
e.g.
RUBYOPT=rubygems
But one why or another you need to tell Ruby that it should load the
rubygems library first, and that then takes care of looking for gem
files.
I guess this puts me at step 0.0.1?
Oh, I say at least 0.1.
–
James B.
“I was born not knowing and have had only a little
time to change that here and there.”
Richard P. Feynman
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.