1
0
Fork 0
mirror of https://github.com/middleman/middleman.git synced 2022-11-09 12:20:27 -05:00

continue fixing config loading

This commit is contained in:
tdreyno 2009-08-04 15:28:25 -07:00
parent a5d56329d7
commit 0755c968ac

View file

@ -50,14 +50,8 @@ class Middleman < Sinatra::Base
puts "== The Middleman is already standing watch on port #{port}!" puts "== The Middleman is already standing watch on port #{port}!"
end end
# Check for local config
local_config = File.join(self.root, "init.rb")
if File.exists? local_config
puts "== Local config at: #{local_config}"
class_eval File.read(local_config)
end
configure do configure do
puts "config yo"
Compass.configuration do |config| Compass.configuration do |config|
config.project_path = Dir.pwd config.project_path = Dir.pwd
config.sass_dir = File.join(File.basename(self.views), "stylesheets") config.sass_dir = File.join(File.basename(self.views), "stylesheets")
@ -66,7 +60,16 @@ class Middleman < Sinatra::Base
config.http_images_path = "/images/" config.http_images_path = "/images/"
config.add_import_path(config.sass_dir) config.add_import_path(config.sass_dir)
end end
end
# Check for local config
local_config = File.join(self.root, "init.rb")
if File.exists? local_config
puts "== Local config at: #{local_config}"
class_eval File.read(local_config)
end
configure do
Compass.configure_sass_plugin! Compass.configure_sass_plugin!
end end