On Sat, 27 Sep 2003 01:43:09 +0900, Gavin Sinclair wrote: >> IMO, the way to avoid bloat is like this: >> ext.rb # loads everything >> ext/numeric >> ext/numeric.rb # loads all extensions to Numeric classes >> ext/numeric/format.rb >> ext/enumerable >> ext/enumerable.rb # loads all extensions to Enumerable >> ext/enumerable/map.rb >> The file ext/numeric/format.rb could contain the number formatting >> routine I wrote and is currently on the RubyGarden wiki. If there are >> other numeric formatting routines, they could be put there as well. The >> file ext/enumerable/map.rb could contain #map_with_index. > What I have chosen is: > require "extensions/all" # everything > require "extensions/enumerable" > require "extensions/io" > require "extensions/string" > Since these deal exclusively with modifications to core classes, it makes > sense to me that the things you load should be named after them. It > doesn't make sense to me that finer granularity is required, because: (a) > it's too much to remember and too much hassle to look up; and (b) the > extensions shouldn't be so numerous as to require it. The reason I suggest it is that while there aren't too many extensions (yet), there are possibilities for more. In the ruwiki stuff that I did for version 0.5.0, I made it so that you can add new transformation items in a subdirectory and they will be loaded appropriately when you load the "main" item, as I've specified. By allowing more specific granularity (and I'm not suggesting file-per-method, but rather "logical" grouping), you make it so that people don't have to load all of the extensions that are available. -austin -- austin ziegler * austin / halostatue.ca * Toronto, ON, Canada software designer * pragmatic programmer * 2003.09.26 * 15.39.48