diff options
Diffstat (limited to 'config/application.rb')
-rw-r--r-- | config/application.rb | 28 |
1 files changed, 27 insertions, 1 deletions
diff --git a/config/application.rb b/config/application.rb index 245a60782..f2b662abc 100644 --- a/config/application.rb +++ b/config/application.rb @@ -6,7 +6,7 @@ require File.dirname(__FILE__) + '/../lib/configuration' # If you have a Gemfile, require the gems listed there, including any gems # you've limited to :test, :development, or :production. -Bundler.require(:default, Rails.env) if defined?(Bundler) +Bundler.require(:default, :assets, Rails.env) if defined?(Bundler) module Alaveteli class Application < Rails::Application @@ -75,5 +75,31 @@ module Alaveteli # Insert a bit of middleware code to prevent uneeded cookie setting. require "#{Rails.root}/lib/whatdotheyknow/strip_empty_sessions" config.middleware.insert_before ::ActionDispatch::Cookies, WhatDoTheyKnow::StripEmptySessions, :key => '_wdtk_cookie_session', :path => "/", :httponly => true + + # Enable the asset pipeline + config.assets.enabled = true + + # Version of your assets, change this if you want to expire all your assets + config.assets.version = '1.0' + + # Change the path that assets are served from + # config.assets.prefix = "/assets" + + # These additional precompiled Javascript files are actually + # manifests that require the real javascript files: + config.assets.precompile += ['admin.js', + 'profile-photos.js', + 'stats.js'] + # ... while these are individual files that can't easily be + # grouped: + config.assets.precompile += ['jquery.fancybox-1.3.4.pack.js', + 'jquery.Jcrop.css', + 'excanvas.min.js', + 'fonts.css', + 'print.css', + 'admin.css', + 'ie6.css', + 'ie7.css'] + end end |