From: Logan Capaldo Date: 2006-08-09T06:33:06+09:00 Subject: Re: load paths unions? On Aug 8, 2006, at 3:40 PM, Trans wrote: > > Logan Capaldo wrote: > >> cd facets >> for each in ../facets/*/*.rb >> do ln -s $each >> done > > Unfortuately that's not cross-platform. > > T. > > Make a rake task to do it? But instead of ln -s just spit out require 'facets/foo/foo.rb' into a file. Ok it's a hack, but require ain't exactly Java's import or C#'s using (which is a good thing, IMO). If you do want this, and you want to do it the "right" (where "right" meets my definition of "right" :) ) way, I think your best bet is build a package/module system, and make it clear that what you are doing is a little smarter than require (aka load_once_if_you_dont_trick_me_somehow_anyway) e.g.: require 'facets/manager' import 'factes.foo.*' Or whatever you want the interface to be. And you can add your .pth type features to this, etc.