How can I make my programs not need to be called *.rb in the require statment? If I have a script called notepad/component.rb, how do make it so that notepad.rb can say require "notepad/component" instead of "notepad/component.rb"?
Thank you
···
---------------------------------
Looking for last minute shopping deals? Find them fast with Yahoo! Search.
On Jan 9, 2008 9:45 PM, MistryMan4000@Yahoo.com <mistryman4000@yahoo.com> wrote:
How can I make my programs not need to be called *.rb in the require
statment? If I have a script called notepad/component.rb, how do make
it so that notepad.rb can say require "notepad/component" instead of
"notepad/component.rb"?
How can I make my programs not need to be called *.rb in the require
statment? If I have a script called notepad/component.rb, how do make it
so that notepad.rb can say require "notepad/component" instead of
"notepad/component.rb"?
Thank you
Hi
You do not need to put the .rb in require.
Try a simple command:
require "dbi" and see the result.