Sync asset configuration with Rails 4.1.4 defaults

Ref #1705
This commit is contained in:
Dan Rice 2014-07-03 22:05:53 -04:00
parent 9a69b170fe
commit c6a8e0f498
4 changed files with 21 additions and 17 deletions

View file

@ -49,18 +49,6 @@ module Tracksapp
# Set timezone of dates in database
config.active_record.default_timezone = :utc
# Disable loading of the full environment when precompiling assets
config.assets.initialize_on_precompile = false
# Version of your assets, change this if you want to expire all your assets
config.assets.version = '1.0'
# add /app/assets/swfs to asset pipeline for charts
config.assets.paths << Rails.root.join("app", "assets", "swfs")
# add print and login css to assets
config.assets.precompile += %w(login.css print.css mobile.css)
# configure Tracks to handle deployment in a subdir
config.action_controller.relative_url_root = SITE_CONFIG['subdir'] if SITE_CONFIG['subdir']

View file

@ -19,9 +19,16 @@ Rails.application.configure do
# Print deprecation notices to the Rails logger
config.active_support.deprecation = :log
# Expands the lines which load the assets
# Debug mode disables concatenation and preprocessing of assets.
# This option may cause significant delays in view rendering with a large
# number of complex assets.
config.assets.debug = true
# Adds additional error checking when serving assets at runtime.
# Checks for improperly declared sprockets dependencies.
# Raises helpful error messages.
config.assets.raise_runtime_errors = true
# Unique cookies
# config.action_controller.session_store :cookie_store, :key => 'TracksCucumber'
# config.action_controller.session = { :key => 'TracksDev' }

View file

@ -32,8 +32,7 @@ Rails.application.configure do
# Generate digests for assets URLs.
config.assets.digest = true
# Version of your assets, change this if you want to expire all your assets.
config.assets.version = '1.0'
# `config.assets.precompile` has moved to config/initializers/assets.rb
# Specifies the header that your server uses for sending files.
# config.action_dispatch.x_sendfile_header = "X-Sendfile" # for apache
@ -60,7 +59,6 @@ Rails.application.configure do
# Precompile additional assets.
# application.js, application.css, and all non-JS/CSS in app/assets folder are already added.
# config.assets.precompile += %w( search.js )
config.assets.precompile += %w( print.css login.css mobile.css )
# Ignore bad email addresses and do not raise email delivery errors.
# Set this to true and configure the email server for immediate delivery to raise delivery errors.

View file

@ -0,0 +1,11 @@
# Be sure to restart your server when you modify this file.
# Version of your assets, change this if you want to expire all your assets.
Rails.application.config.assets.version = '1.0'
# Precompile additional assets.
# application.js, application.css, and all non-JS/CSS in app/assets folder are already added.
Rails.application.config.assets.precompile += %w( print.css login.css mobile.css )
# add /app/assets/swfs to asset pipeline for charts
Rails.application.config.assets.paths << Rails.root.join("app", "assets", "swfs")