NAME
App::Dataninja::Config - App::Dataninja configuration through YAML files
DESCRIPTION
This is the class you use to grab information from config files, such as the channels that the bot connects to, his nick, database information, that list goes on.
There are three attributes: there are three configurations: default, site, and secret. In the end, the configurations are merged (secret having the most precedence, and default having the least).
ATTRIBUTES
default_config
(Str
) File for the default configuration for App::Dataninja (for things such as database name and host). If no file is specified, it defaults to ~/.dataninja/config.yml
.
site_config
(Str
) File for site-specific information. This includes things like IRC networks, channels, command prefixes, and any custom data you like. The file defaults to ~/.dataninja/site_config.yml
. See ~/.dataninja/example_site_config.yml
for details.
secret_config
(Str
) File for storing secret information such as passwords. This file defaults to ~/.dataninja/secret_config
.
main
(HashRef
) The object that has all the configuation information for the main configuration, such as database information.
site
(HashRef
) The object that has all the site-specific configuation information, such as external applicaiton credentials, channels, the nick of the bot, etc.