Method: Jekyll.configuration
- Defined in:
- lib/ngage/jekyll.rb
.configuration(override = {}) ⇒ Object
Public: Generate a Jekyll configuration Hash by merging the default options with anything in _config.yml, and adding the given options on top.
override - A Hash of config directives that override any options in both
the defaults and the config file.
See Jekyll::Configuration::DEFAULTS for a
list of option names and their defaults.
Returns the final configuration Hash.
109 110 111 112 113 114 115 116 117 118 119 120 |
# File 'lib/ngage/jekyll.rb', line 109 def configuration(override = {}) config = Configuration.new override = Configuration[override].stringify_keys unless override.delete("skip_config_files") config = config.read_config_files(config.config_files(override)) end # Merge DEFAULTS < _config.yml < override Configuration.from(Utils.deep_merge_hashes(config, override)).tap do |obj| set_timezone(obj["timezone"]) if obj["timezone"] end end |