Persist Config v0.2.1 PersistConfig View Source
Persists configuration files and puts the current app in module attribute @app (or in one of your choice).
Option :app_attr
identifies the module attribute where
to put the current app.
Option :files
lists the configuration files to be persisted.
Each entry represents a (wildcard) path relative to the root.
If the list is or ends up being empty, no files are persisted.
Configuration files must be imported in the config/config.exs
.
For example: import_config "config/persist_this_config.exs"
.
Options
:app_attr
- module attribute for current app, defaults to:app
:files
- (wildcard) paths, defaults to["config/persist*.exs"]
Usage
use PersistConfig files: ["config/persist_styles.exs"]
@some_value Application.get_env(@app, :some_key)
use PersistConfig, app_attr: :my_app
@my_value Application.get_env(@my_app, :my_key)