RichardOnRails
11/5/2008 9:18:00 PM
On Nov 4, 12:22 pm, Kenneth McDonald
<kenneth.m.mcdon...@sbcglobal.net> wrote:
> At our site, newly started using Ruby, we're now starting to get code
> we'd like to make generally available via 'require'. What is the
> standard location/method for doing this? Can it be done in such a
> manner that rdoc and ri documentation is made available to the site,
> preferably integrated with the rest of the ruby docs on this site?
>
> Thanks,
> Ken McDonald
The place you want is ruby\lib\ruby\site_ruby.
For example, I have my home-grown utility Search.rb stored there,
which defines a Search class. Then a Ruby program stored anywhere can
simply include:
require 'search' # case-insensitive on WinXP, e.g.
s = Seach.new # etc.
HTH,
Richard