Re: XML and Config files

David Nicol <[email protected]>
Newsgroups gmane.comp.lang.perl.xml
Message-ID <[email protected]>
On Fri, Mar 20, 2009 at 4:31 PM, G. Wade Johnson <[email protected]> wrote:

> In other words, if your configuration involves complex, nested objects,
> XML is probably a reasonable choice. If your configuration involves 5
> named scalar values, INI or property files might be more appropriate.
>
> G. Wade

in which case,

    my %CONFIG = (%DEFAULTS, map { /^\s*(\w)\s*=\s*(.+?)\s*$/ ?
($1,$2) : () } `cat $ConfigFile`);

may be all you need.
_______________________________________________
Perl-XML mailing list
[email protected]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.