On 11/14/2011 06:51 PM, Daniel Perrett wrote:
Is indenting with tabs a problem specific to Dancer users? I would say
not, unless we count "not knowing YAML" as a likely property of Dancer
users

Therefore, I would think if it is worth implementing this, it is worth
doing so in the YAML module.

If "not knowing YAML" is a likely property of Dancer users, then updating
the documentation would seem a simpler solution than writing a custom
error checker feature.

Interestingly, the documentation already states that config.yml is a YAML
file.

Config.pm currently reads:

A better way of defining settings exists: using YAML file. For this to be
possible, you have to install the L<YAML>  module. If a file named
B<config.yml>
exists in the application directory, it will be loaded, as a setting
group.

It could read (note "a YAML file" on first line):

A better way of defining settings exists: using a YAML file. For this to
be
possible, you have to install the L<YAML>  module. If a file named
B<config.yml>
exists in the application directory, it will be loaded, as a setting
group.
If the file exists but is not valid YAML (for example, if it contains
unquoted
tab characters or does not end in a new line), YAML - and Dancer - will
die.

IMHO Dancer::Config should be the other way around, explaining how the
configuration file works and give some hints about YAML in the beginning
and put the set keyword at the end. This is how most users will start
with Dancer Configuration.

Regards
        Racke

--
LinuXia Systems => http://www.linuxia.de/
Expert Interchange Consulting and System Administration
ICDEVGROUP => http://www.icdevgroup.org/
Interchange Development Team

_______________________________________________
Dancer-users mailing list
[email protected]
http://www.backup-manager.org/cgi-bin/listinfo/dancer-users

Reply via email to