From 8c1372afc648b92e33d24645aed87e2ab39c9a03 Mon Sep 17 00:00:00 2001 From: did Date: Tue, 28 Jun 2011 17:35:25 +0200 Subject: [PATCH] fixing the heroku version --- config/initializers/locomotive.rb | 2 -- .../locomotive/install/templates/locomotive.rb | 16 ++++++++++++++-- lib/locomotive/engine.rb | 1 + lib/tasks/rspec.rake | 3 +++ 4 files changed, 18 insertions(+), 4 deletions(-) diff --git a/config/initializers/locomotive.rb b/config/initializers/locomotive.rb index b8742900..ff9966b1 100644 --- a/config/initializers/locomotive.rb +++ b/config/initializers/locomotive.rb @@ -75,5 +75,3 @@ Locomotive.configure do |config| # Note: by default, rack/cache is disabled in the Heroku platform end unless Locomotive.engine? || Rails.env.test? - -# Rails.application.middleware.use '::Locomotive::Middlewares::SeoTrailingSlash' diff --git a/lib/generators/locomotive/install/templates/locomotive.rb b/lib/generators/locomotive/install/templates/locomotive.rb index fadfe4df..56f7a74c 100644 --- a/lib/generators/locomotive/install/templates/locomotive.rb +++ b/lib/generators/locomotive/install/templates/locomotive.rb @@ -46,7 +46,7 @@ Locomotive.configure do |config| # configure how many items we display in sub menu in the "Contents" section. # config.lastest_items_nb = 5 - # default locale (for now, only en, de, fr and pt-BR are supported) + # default locale (for now, only en, de, fr, pt-BR and it are supported) config.default_locale = :en # tell if logs are enabled. Useful for debug purpose. @@ -60,4 +60,16 @@ Locomotive.configure do |config| # config.mailer_sender = 'support' # # => 'support@heroku.com' (Heroku), 'support@bushi.do' (Bushido), 'support@example.com' (Dev) or 'support@' (Multi-sites) config.mailer_sender = 'support' -end + + # Rack-cache settings, mainly used for the inline resizing image module. Default options: + # config.rack_cache = { + # :verbose => true, + # :metastore => URI.encode("file:#{Rails.root}/tmp/dragonfly/cache/meta"), # URI encoded in case of spaces + # :entitystore => URI.encode("file:#{Rails.root}/tmp/dragonfly/cache/body") + # } + # If you do want to disable it for good, just use the following syntax + # config.rack_cache = false + # + # Note: by default, rack/cache is disabled in the Heroku platform + +end \ No newline at end of file diff --git a/lib/locomotive/engine.rb b/lib/locomotive/engine.rb index 59421052..6469e10e 100644 --- a/lib/locomotive/engine.rb +++ b/lib/locomotive/engine.rb @@ -21,6 +21,7 @@ require 'redcloth' require 'delayed_job_mongoid' require 'zip/zipfilesystem' require 'jammit-s3' +require 'dragonfly' $:.unshift File.dirname(__FILE__) diff --git a/lib/tasks/rspec.rake b/lib/tasks/rspec.rake index b7f59671..00af7644 100644 --- a/lib/tasks/rspec.rake +++ b/lib/tasks/rspec.rake @@ -5,6 +5,9 @@ rescue MissingSourceFile module Rspec module Core class RakeTask + + include ::Rake::DSL + def initialize(name) task name do # if rspec-rails is a configured gem, this will output helpful material and exit ...