lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

It was thus said that the Great Pierre Chapuis once stated:
> Finally, I am starting to like the practice of module
> namespacing by organization, i.e. "mycompany.util.stack".
> However when doing this I am unsure how to package those
> modules as rocks. Make a single "mycompany" rock?
> Make "mycompany-util"? Make "mycompany-util-stack"?
> For close source, pure Lua modules I am shifting towards
> the second solution, but still allow users to just require
> a part of it (i.e. the Penlight model minus the global
> namespace pollution when requiring "pl"). For Open
> Source the third one appears to make more sense, but
> I am wondering if the trade-off in usability from the
> second one would not make sense as well ("mycompany"
> could be anything else, like "org.conman" here).

  As the creator of "org.conman", my case is slightly different in that each
module is pretty independent of the others (a few exceptions, like
"org.conman.string" requires "org.conman.strcore" and ""
requires "org.conman.tcc" [1]).  As such, I have created separate rockspec
files for each module (only a few are published on as it makes
sense for these modules.  As for names:


  -spc (But no "org.conman" or "org.conman.parsers" oddly enough ... )

[1]	A TCC (a C-compiler as library) wrapper.  I would not recoomend this
	at all, as TCC is, unfortunately, pretty rough around the edges.