spf13/viper — pull request #9 by natefinch (2014-08-05 11:43:33+00:00)
Title: Fix issue #8 - aliases in config files

(note, this includes my other pull request which fixes the tests so they can run)

This fixes issue #8, the aliases in config files bug. Whenever we register an alias, if there is a value in the config (or defaults or override) for the alias, we move that value to the new "real key".

Added a test for the bug, which fails without the changes and passes with the changes.

This also fixes a bug in Hugo, where specifying "Taxonomies" in your config file doesn't get recognized, because Hugo aliases "Taxonomies" to "Indexes" which means that when the code does a Get("Taxnomies") it got translated to Get("Indexes"), which didn't exist in the original config map.