Catalyst moves away from YAML

Posted by on July 10, 2008

It appears that to the Catalyst community YAML isn’t the best config file format any longer as they’ve chosen to switch in favor of Config::General – which defaults to the "apache config format"

From Config::General’s POD:

The format of config files supported by Config::General is inspired by the well known apache config format, in fact, this module is 100% compatible to apache configs, but you can also just use simple name/value pairs in your config files.

Catalyst::Plugin::DebugCookie even provides the updated configuration style in it’s POD:
 <Plugin::DebugCookie>
secret_key 001A4B28EE3936
cookie_name my_secure_debug_cookie
</Plugin::DebugCookie>

The following command can be used to dump an existing Catalyst app’s config into an Apache style conf file. You’ll definitely have to edit the resulting file, but at least it’s a start.

perl -Ilib -e ‘use MyApp; use Config::General; Config::General→new→save_file(“myapp.conf”, MyApp→config);’