[Wellington-pm] Complex config files
lrw at clear.net.nz
Wed May 13 23:04:49 PDT 2009
Thanks for all the input. Looking at what we already have installed on
our servers, it's probably either going to be XML::Simple or YAML. Not
that that it's hard to install a CPAN module or anything, but I really
dislike unnecessary bloatage.
(On further reflection I've decided that for my current purpose human
editing may not be required after all)
Lesley Longhurst wrote:
> Hi all,
> Some of you may remember a while ago I brought in some code from work
> to talk about, and it was based around a truly hideous config file.
> I'm now working on replacing some of that stuff with a new script, and
> the time has come to invent a better config file format. So, I'm
> interested in recommendations for a good module to use for reading and
> writing complex config files.
> Ideally, such a module would meet the following requirements:
> - well-documented
> - currently supported
> - a usable version available in a Debian package for Etch
> and the config file itself needs to
> - be easily read and edited by humans
> - support repeated sub-sections
> - allow multiple entries for parameters within the same section and
> - allow for lots of comments
> Any suggestions?
> By way of example, I've attached a first cut of the sort of thing I'm
> thinking of (and for your amusement I've also attached a fragment of
> the existing config file that I derived it from.)
More information about the Wellington-pm