Can't access config file values

29 views
Skip to first unread message

Jason Brinton

unread,
Apr 20, 2012, 2:28:57 PM4/20/12
to mojol...@googlegroups.com
I'm a bit new to Perl, and newer to Mojo, and I'm confused as to how I can take values in my config file and use them in my application.

If I have { foo => 'bar' } in my config file, I feel like I should be able to just call $config->{'foo'} anywhere in my application to test for bar, but I'm not sure what $config should be, and I'm not sure if I need to use any extra classes to get configuration files working or not. It seems like config should be available by default, but the documentation isn't terribly helpful for me.

I hope this makes sense to someone out there.


Jason Brinton

unread,
Apr 20, 2012, 3:07:26 PM4/20/12
to mojol...@googlegroups.com
Nevermind; I think I've figured it out. I was failing to call the Config plugin in the startup method.
Reply all
Reply to author
Forward
0 new messages