Handles recursive expansion
Fixes override
Major refactoring mainly revolving around a class to represent configs
Removes dead code