From 16178759344781e9e19162b3b766e9c737fdf619 Mon Sep 17 00:00:00 2001 From: Ben Hollis Date: Sun, 7 Apr 2013 23:33:40 -0700 Subject: [PATCH] Activate Sprockets before user config --- .../middleman-core/core_extensions/extensions.rb | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/middleman-core/lib/middleman-core/core_extensions/extensions.rb b/middleman-core/lib/middleman-core/core_extensions/extensions.rb index a9efd153..44d4b7d1 100644 --- a/middleman-core/lib/middleman-core/core_extensions/extensions.rb +++ b/middleman-core/lib/middleman-core/core_extensions/extensions.rb @@ -128,13 +128,6 @@ module Middleman # Search the root of the project for required files $LOAD_PATH.unshift(root) - # Check for and evaluate local configuration - local_config = File.join(root, "config.rb") - if File.exists? local_config - logger.debug "== Reading: Local config" - instance_eval File.read(local_config), local_config, 1 - end - if config[:autoload_sprockets] begin require "middleman-sprockets" @@ -143,6 +136,13 @@ module Middleman end end + # Check for and evaluate local configuration + local_config = File.join(root, "config.rb") + if File.exists? local_config + logger.debug "== Reading: Local config" + instance_eval File.read(local_config), local_config, 1 + end + run_hook :build_config if build? run_hook :development_config if development?