Forum: Ruby on Rails how to call the file?

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
0b119a0054ac02e180950a8d247a4fbe?d=identicon&s=25 Selvaraj (Guest)
on 2007-05-25 17:35
      I have created one folder in lib called 'commands'. And i created
one file called get.rb inside that commands folder. How can i call that
file from some other rb file.? Whether i need to use 'include' ? or any
other best way ?
2f9a03aa0fcfe945229cb6126eda2cb2?d=identicon&s=25 Philip Hallstrom (Guest)
on 2007-05-25 18:19
(Received via mailing list)
>      I have created one folder in lib called 'commands'. And i created
> one file called get.rb inside that commands folder. How can i call that
> file from some other rb file.? Whether i need to use 'include' ? or any
> other best way ?

require 'commands/get'

should do it.
This topic is locked and can not be replied to.