zotonic/zotonic — pull request #650 by jarimatti (2013-09-10 09:21:13+00:00)
Title: Allow splitting the config file (issue #648)

Read configuration settings also from site/config.d. Files starting with '.' and ending with '~' are ignored. This makes it possible to split configuration between multiple files, which should make e.g. site deployment easier.

Configuration is read as follows:
1. Master Zotonic configuration file priv/config.
2. Site specific master configuration file site/config.
3. Site specific configuration files in directory site/config.d.

The latest setting always override previous ones. The files in config.d are read in the order of lists:sort, which is roughly alphabetical with upper case first.