diff --git a/lib/compass/app_integration/rails/action_controller.rb b/lib/compass/app_integration/rails/actionpack2/action_controller.rb similarity index 100% rename from lib/compass/app_integration/rails/action_controller.rb rename to lib/compass/app_integration/rails/actionpack2/action_controller.rb diff --git a/lib/compass/app_integration/rails/sass_plugin.rb b/lib/compass/app_integration/rails/actionpack2/sass_plugin.rb similarity index 100% rename from lib/compass/app_integration/rails/sass_plugin.rb rename to lib/compass/app_integration/rails/actionpack2/sass_plugin.rb diff --git a/lib/compass/app_integration/rails/urls.rb b/lib/compass/app_integration/rails/actionpack2/urls.rb similarity index 100% rename from lib/compass/app_integration/rails/urls.rb rename to lib/compass/app_integration/rails/actionpack2/urls.rb diff --git a/lib/compass/app_integration/rails/runtime.rb b/lib/compass/app_integration/rails/runtime.rb index 82a353d1..d1a5ed5b 100644 --- a/lib/compass/app_integration/rails/runtime.rb +++ b/lib/compass/app_integration/rails/runtime.rb @@ -1,10 +1,14 @@ unless defined?(Compass::RAILS_LOADED) Compass::RAILS_LOADED = true - - %w(action_controller sass_plugin urls).each do |lib| - require "compass/app_integration/rails/#{lib}" + + if ActionPack::VERSION::MAJOR >= 3 + # figure something out so image_path works with rails integration + else + %w(action_controller sass_plugin urls).each do |lib| + require "compass/app_integration/rails/actionpack2/#{lib}" + end end - + # Wierd that this has to be re-included to pick up sub-modules. Ruby bug? class Sass::Script::Functions::EvaluationContext include Sass::Script::Functions