From: "Y. NOBUOKA" Date: 2011-02-06T22:05:09+09:00 Subject: Re: require does not work Hi, Tony Please see the FAQ of Ruby 1.9.2: http://www.ruby-lang.org/en/news/2010/08/18/ruby-1-9.2-released/#label-7 It says: > It causes a LoadError > $: doesn't include the current directory. Some script may > need modifications to work properly. The global variable $: (equivalent to $LOAD_PATH) is the list of load path, which is used by the require method. If you want to load your own ruby module which exists in the directory /path/to/moddir, you need to append the path to $LOAD_PATH before using the require method. #stack.rb # append the path into the load path list $LOAD_PATH << "/path/to/moddir" require "stacklike" class Stack include Stacklike end s = Stack.new Another way to append a path into $LOAD_PATH is to use a command line option "-I". $ ruby -I /path/to/moddir stack.rb Regards, -- nobuoka