From: Robert Klemme Date: 2005-03-21T18:29:50+09:00 Subject: Re: Crobjob problem with ruby script. schrieb im Newsbeitrag news:1111353483.371443.9470@g14g2000cwa.googlegroups.com... > > Robert Klemme wrote: > > Try doing this on the shell and set $LOAD_PATH accordingly before the > first > > require: > > > > ruby -e 'puts $LOAD_PATH.join(":")' > > > > Alternatively you might have a permissions problem but I think path > is more > > likely. > > > > Kind regards > > > > robert > > Good Evening Robert! > > Thanks for supporting me with my silly but serious problem.. :) > > I have spotted a big difference between the $LOAD_PATH of the shell and > executing the same from the cronjob. How can I set the correct > $LOAD_PATH inside the rubyscript? > > $LOAD_PATH of the shell: > /usr/local/lib/ruby/site_ruby:/usr/local/lib/ruby/site_ruby/1.8:/usr/local /lib/ruby/1.8/:/usr/local/lib/ruby/site_ruby/1.8/i686-linux/:/usr/local/li b/ruby/1.8/i686-linux/:/usr/lib/ruby/site_ruby/1.8:/usr/lib/ruby/site_ruby /1.8/i686-linux:/usr/lib/ruby/site_ruby:/usr/lib/ruby/1.8:/usr/lib/ruby/1. 8/i686-linux:. > > $LOAD_PATH of the cronjob: > /usr/lib/ruby/site_ruby/1.8:/usr/lib/ruby/site_ruby/1.8/i686-linux:/usr/li b/ruby/site_ruby:/usr/lib/ruby/1.8:/usr/lib/ruby/1.8/i686-linux:. > > Now that's a difference.. :) > > Any suggestions on how I may add the missing paths? See my posting to the other branch of the thread. robert