mojombo/jekyll — pull request #896 by voidfiles (2013-03-29 04:51:28+00:00)
Title: Added config includes to solve #514 and #703

This is originally from this checkin.
https://github.com/xenji/jekyll/commit/29612017f6a84eb02714693738d5031209bfd87a

I have only tried to cherry pick it on top of the current source
tree

Added config includes to solve #514 and #703
including the corresponding tests and fixtures.

You can now use a YAML list to add configuration files to be included
in the order of the list. The main configuration is included at the
final step to ensure that every value can be overridden.

The syntax supports globs (to be used with `Dir[pattern]`), relative
paths to the config value of `source` and absolute paths.

Using this sample config:
```
additional_configs:
- additional_configs/_config_a.yml
- additional_configs/_config_b.yml
```
or the glob version:
```
additional_configs:
- additional_configs/_config_*.yml
```
the new deep merge order is in both cases:
`Jekyll::DEFAULTS < _config_a < _config_b < _config`

Using globs means to rely on the sorting that Dir[pattern] resolves.

I've added additional tests for three use cases:
* Having one inclusion
* Having a glob inclusion
* Having one inclusion with override in the main config