Require library path

Hi,

I want to load the date.rb file, but require 'date' results in :

./mk.rb:4:in `require': no such file to load -- date (LoadError)
        from ./mk.rb:4

ruby is installed in ~/ruby/rubyinstall/

Apparently Ruby does not look over there, where is Ruby's library path defined?

Thanx!

Krekna

"Krekna Mektek" <krekna@gmail.com> wrote/schrieb <8b24c8b10701300758y5e670cb1ob1d26609855a589c@mail.gmail.com>:

Apparently Ruby does not look over there, where is Ruby's library
path defined?

Run this on the shell and look at the output:
ruby -e 'puts $:'

You may consider to set the environvent variable RUBYOPT, e.g. (bash):
export RUBYOPT=r${HOME}/ruby/rubyinstall

Regards
  Thomas

thanks, I did the following now:

$:.push("~/ruby/rubyinstall/lib... etc")

It seems that the problem is that I compiled in the /tmp directory so
the library path points to /tmp/ruby/rubyinstall. I think I need to
recompile to get it in order again.

Krekna

···

2007/1/30, Thomas Hafner <thomas@hafner.nl.eu.org>:

"Krekna Mektek" <krekna@gmail.com> wrote/schrieb <8b24c8b10701300758y5e670cb1ob1d26609855a589c@mail.gmail.com>:

> Apparently Ruby does not look over there, where is Ruby's library
> path defined?

Run this on the shell and look at the output:
ruby -e 'puts $:'

You may consider to set the environvent variable RUBYOPT, e.g. (bash):
export RUBYOPT=r${HOME}/ruby/rubyinstall

Regards
  Thomas