Skip to content
This repository was archived by the owner on May 25, 2022. It is now read-only.

Commit

Permalink
Update rails to version 4.0.8
Browse files Browse the repository at this point in the history
  • Loading branch information
sferik committed Jul 30, 2014
1 parent f8f72e4 commit 83b453b
Show file tree
Hide file tree
Showing 29 changed files with 296 additions and 128 deletions.
2 changes: 1 addition & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ source 'https://rails-assets.org'
gem 'rapidftr_addon', :git => 'https://github.com/rapidftr/rapidftr-addon.git', :branch => 'master'
gem 'rapidftr_addon_cpims', :git => 'https://github.com/rapidftr/rapidftr-addon-cpims.git', :branch => 'master'

gem 'rails', '4.0.3'
gem 'rails', '~> 4.0.8'
gem 'couchrest_model', '~> 2.0.1'
gem 'mini_magick', '~> 3.8'
gem 'prawn', '~> 0.8.4'
Expand Down
46 changes: 23 additions & 23 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -30,26 +30,26 @@ GEM
remote: https://rails-assets.org/
specs:
Ascii85 (1.0.2)
actionmailer (4.0.3)
actionpack (= 4.0.3)
actionmailer (4.0.8)
actionpack (= 4.0.8)
mail (~> 2.5.4)
actionpack (4.0.3)
activesupport (= 4.0.3)
actionpack (4.0.8)
activesupport (= 4.0.8)
builder (~> 3.1.0)
erubis (~> 2.7.0)
rack (~> 1.5.2)
rack-test (~> 0.6.2)
activemodel (4.0.3)
activesupport (= 4.0.3)
activemodel (4.0.8)
activesupport (= 4.0.8)
builder (~> 3.1.0)
activerecord (4.0.3)
activemodel (= 4.0.3)
activerecord (4.0.8)
activemodel (= 4.0.8)
activerecord-deprecated_finders (~> 1.0.2)
activesupport (= 4.0.3)
activesupport (= 4.0.8)
arel (~> 4.0.0)
activerecord-deprecated_finders (1.0.3)
activesupport (4.0.3)
i18n (~> 0.6, >= 0.6.4)
activesupport (4.0.8)
i18n (~> 0.6, >= 0.6.9)
minitest (~> 4.2)
multi_json (~> 1.3)
thread_safe (~> 0.1)
Expand Down Expand Up @@ -174,20 +174,20 @@ GEM
rack (1.5.2)
rack-test (0.6.2)
rack (>= 1.0)
rails (4.0.3)
actionmailer (= 4.0.3)
actionpack (= 4.0.3)
activerecord (= 4.0.3)
activesupport (= 4.0.3)
rails (4.0.8)
actionmailer (= 4.0.8)
actionpack (= 4.0.8)
activerecord (= 4.0.8)
activesupport (= 4.0.8)
bundler (>= 1.3.0, < 2.0)
railties (= 4.0.3)
sprockets-rails (~> 2.0.0)
railties (= 4.0.8)
sprockets-rails (~> 2.0)
rails-assets-jquery (2.1.1)
rails-assets-select2 (3.5.1)
rails-assets-jquery (>= 1.7.1)
railties (4.0.3)
actionpack (= 4.0.3)
activesupport (= 4.0.3)
railties (4.0.8)
actionpack (= 4.0.8)
activesupport (= 4.0.8)
rake (>= 0.8.7)
thor (>= 0.18.1, < 2.0)
rainbow (2.0.0)
Expand Down Expand Up @@ -259,7 +259,7 @@ GEM
multi_json (~> 1.0)
rack (~> 1.0)
tilt (~> 1.1, != 1.3.0)
sprockets-rails (2.0.1)
sprockets-rails (2.1.3)
actionpack (>= 3.0)
activesupport (>= 3.0)
sprockets (~> 2.8)
Expand Down Expand Up @@ -322,7 +322,7 @@ DEPENDENCIES
progress_bar (~> 1.0.2)
pry-rails (~> 0.3.2)
quiet_assets (~> 1.0.3)
rails (= 4.0.3)
rails (~> 4.0.8)
rails-assets-select2 (~> 3.5.0)
rake (~> 10.3)
rapidftr_addon!
Expand Down
File renamed without changes.
2 changes: 2 additions & 0 deletions app/controllers/application_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
#

class ApplicationController < ActionController::Base
protect_from_forgery with: :null_session

helper :all
helper_method :current_user_name, :current_user, :current_user_full_name, :current_session, :logged_in?

Expand Down
Empty file added app/controllers/concerns/.keep
Empty file.
Empty file added app/mailers/.keep
Empty file.
Empty file added app/models/.keep
Empty file.
Empty file added app/models/concerns/.keep
Empty file.
2 changes: 1 addition & 1 deletion app/views/duplicates/new.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
<br />
<div class="btn_panel">
<%= link_to t("child.actions.cancel"), children_path %>
<%= submit_tag(t("child.mark_as_duplicate"), :confirm => t("child.messages.confirm_duplicate")) %>
<%= submit_tag(t("child.mark_as_duplicate"), data: { confirm: t("child.messages.confirm_duplicate") }) %>
</div>
<% end %>
</div>
Expand Down
2 changes: 1 addition & 1 deletion app/views/replications/_index.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
&nbsp;
<%= link_to t("buttons.edit"), edit_replication_path(rep) %>
&nbsp;
<%= link_to t("buttons.delete"), replication_path(rep), :confirm => t("replication.confirm_delete"), :method => :delete %>
<%= link_to t("buttons.delete"), replication_path(rep), data: { confirm: t("replication.confirm_delete") }, :method => :delete %>
</td>
</td>
</tr>
Expand Down
2 changes: 1 addition & 1 deletion app/views/system_users/index.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
<td>
<%= link_to t("buttons.edit"), edit_system_user_path(user.name) %>
&nbsp;
<%= link_to t("buttons.delete"), system_user_path(user.name), :confirm => t("user.messages.confirmation"), :method => :delete %>
<%= link_to t("buttons.delete"), system_user_path(user.name), data: { confirm: t("user.messages.confirmation") }, method: :delete %>
</td>
</td>
</tr>
Expand Down
2 changes: 1 addition & 1 deletion config.ru
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# This file is used by Rack-based servers to start the application.

require ::File.expand_path('../config/environment', __FILE__)
run RapidFTR::Application
run Rails.application
9 changes: 5 additions & 4 deletions config/application.rb
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
# encoding: utf-8

require File.expand_path('../boot', __FILE__)

require "action_controller/railtie"
Bundler.require(:default, Rails.env) if defined? Bundler
require 'action_controller/railtie'

# Require the gems listed in Gemfile, including any gems
# you've limited to :test, :development, or :production.
Bundler.require(*Rails.groups)

module RapidFTR
class Application < Rails::Application
Expand Down
2 changes: 0 additions & 2 deletions config/boot.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
require 'rubygems'

# Set up gems listed in the Gemfile.
ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile', __FILE__)

Expand Down
4 changes: 2 additions & 2 deletions config/environment.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Load the rails application
# Load the Rails application.
require File.expand_path('../application', __FILE__)

# Initialize the rails application
# Initialize the Rails application.
RapidFTR::Application.initialize!
18 changes: 10 additions & 8 deletions config/environments/development.rb
Original file line number Diff line number Diff line change
@@ -1,23 +1,25 @@
RapidFTR::Application.configure do
# Settings specified here will take precedence over those in config/application.rb
# Settings specified here will take precedence over those in config/application.rb.

# In the development environment your application's code is reloaded on
# every request. This slows down response time but is perfect for development
# since you don't have to restart the webserver when you make code changes.
# every request. This slows down response time but is perfect for development
# since you don't have to restart the web server when you make code changes.
config.cache_classes = false

# Do not eager load code on boot.
config.eager_load = false
config.cache_store = :null_store

# Show full error reports and disable caching
# Show full error reports and disable caching.
config.consider_all_requests_local = true
config.action_controller.perform_caching = false

# Print deprecation notices to the Rails logger
# Print deprecation notices to the Rails logger.
config.active_support.deprecation = :log

# Asset pipeline
# 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.compress = false
config.assets.debug = true

config.eager_load = false
end
79 changes: 69 additions & 10 deletions config/environments/production.rb
Original file line number Diff line number Diff line change
@@ -1,22 +1,81 @@
RapidFTR::Application.configure do
# The production environment is meant for finished, "live" apps.
# Code is not reloaded between requests
# Settings specified here will take precedence over those in config/application.rb.

# Code is not reloaded between requests.
config.cache_classes = true

# Full error reports are disabled and caching is turned on
config.consider_all_requests_local = false
# Eager load code on boot. This eager loads most of Rails and
# your application in memory, allowing both thread web servers
# and those relying on copy on write to perform better.
# Rake tasks automatically ignore this option for performance.
config.eager_load = true

# Full error reports are disabled and caching is turned on.
config.consider_all_requests_local = false
config.action_controller.perform_caching = true

# See everything in the log (default is :info)
config.log_level = :error
# Enable Rack::Cache to put a simple HTTP cache in front of your application
# Add `rack-cache` to your Gemfile before enabling this.
# For large-scale production use, consider using a caching reverse proxy like nginx, varnish or squid.
# config.action_dispatch.rack_cache = true

# Enable locale fallbacks for I18n (makes lookups for any locale fall back to
# the I18n.default_locale when a translation can not be found)
config.i18n.fallbacks = true
# Disable Rails's static asset server (Apache or nginx will already do this).
config.serve_static_assets = false

# Asset pipeline
config.action_dispatch.x_sendfile_header = 'X-Accel-Redirect'

# Compress JavaScripts and CSS.
config.assets.js_compressor = :uglifier
# config.assets.css_compressor = :sass

# Do not fallback to assets pipeline if a precompiled asset is missed.
config.assets.compile = false

# Generate digests for assets URLs.
config.assets.digest = true
config.assets.compress = true

# Version of your assets, change this if you want to expire all your assets.
config.assets.version = '1.0'

# Specifies the header that your server uses for sending files.
# config.action_dispatch.x_sendfile_header = "X-Sendfile" # for apache
# config.action_dispatch.x_sendfile_header = 'X-Accel-Redirect' # for nginx

# Force all access to the app over SSL, use Strict-Transport-Security, and use secure cookies.
# config.force_ssl = true

# Set to :debug to see everything in the log.
config.log_level = :error

# Prepend all log lines with the following tags.
# config.log_tags = [ :subdomain, :uuid ]

# Use a different logger for distributed setups.
# config.logger = ActiveSupport::TaggedLogging.new(SyslogLogger.new)

# Use a different cache store in production.
# config.cache_store = :mem_cache_store

# Enable serving of images, stylesheets, and JavaScripts from an asset server.
# config.action_controller.asset_host = "http://assets.example.com"

# 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.action_dispatch.x_sendfile_header = 'X-Accel-Redirect'

# Enable locale fallbacks for I18n (makes lookups for any locale fall back to
# the I18n.default_locale when a translation can not be found).
config.i18n.fallbacks = true

# Send deprecation notices to registered listeners.
config.active_support.deprecation = :notify

# Disable automatic flushing of the log to improve performance.
# config.autoflush_log = false

# Use default logging formatter so that PID and timestamp are not suppressed.
config.log_formatter = ::Logger::Formatter.new
end
28 changes: 16 additions & 12 deletions config/environments/test.rb
Original file line number Diff line number Diff line change
@@ -1,31 +1,35 @@
RapidFTR::Application.configure do
# Settings specified here will take precedence over those in config/application.rb
# Settings specified here will take precedence over those in config/application.rb.

# The test environment is used exclusively to run your application's
# test suite. You never need to work with it otherwise. Remember that
# test suite. You never need to work with it otherwise. Remember that
# your test database is "scratch space" for the test suite and is wiped
# and recreated between test runs. Don't rely on the data there!
# and recreated between test runs. Don't rely on the data there!
config.cache_classes = true

# Do not eager load code on boot. This avoids loading your whole application
# just for the purpose of running a single test. If you are using a tool that
# preloads Rails for running tests, you may have to set it to true.
config.eager_load = false
config.cache_store = :null_store

# Show full error reports and disable caching
# Configure static asset server for tests with Cache-Control for performance.
config.serve_static_assets = false
config.static_cache_control = "public, max-age=3600"

# Show full error reports and disable caching.
config.consider_all_requests_local = true
config.action_controller.perform_caching = false

# Raise exceptions instead of rendering exception templates
# Raise exceptions instead of rendering exception templates.
config.action_dispatch.show_exceptions = false

# Disable request forgery protection in test environment
config.action_controller.allow_forgery_protection = false
# Disable request forgery protection in test environment.
config.action_controller.allow_forgery_protection = false

# Print deprecation notices to the stderr
# Print deprecation notices to the stderr.
config.active_support.deprecation = :stderr

# Asset pipeline
config.serve_static_assets = false
config.static_cache_control = "public, max-age=3600"

# Disable all logging and remove extra middleware if running in CI
if ENV['CI'] == 'true'
config.log_level = :error
Expand Down
4 changes: 4 additions & 0 deletions config/initializers/filter_parameter_logging.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# Be sure to restart your server when you modify this file.

# Configure sensitive parameters which will be filtered from the log file.
Rails.application.config.filter_parameters += [:password]
7 changes: 4 additions & 3 deletions config/initializers/inflections.rb
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
# Be sure to restart your server when you modify this file.

# Add new inflection rules using the following format
# (all these examples are active by default):
# ActiveSupport::Inflector.inflections do |inflect|
# Add new inflection rules using the following format. Inflections
# are locale specific, and you may define rules for as many different
# locales as you wish. All of these examples are active by default:
# ActiveSupport::Inflector.inflections(:en) do |inflect|
# inflect.plural /^(ox)$/i, '\1en'
# inflect.singular /^(ox)en/i, '\1'
# inflect.irregular 'person', 'people'
Expand Down
14 changes: 14 additions & 0 deletions config/initializers/wrap_parameters.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# Be sure to restart your server when you modify this file.

# This file contains settings for ActionController::ParamsWrapper which
# is enabled by default.

# Enable parameter wrapping for JSON. You can disable this by setting :format to an empty array.
ActiveSupport.on_load(:action_controller) do
wrap_parameters format: [:json] if respond_to?(:wrap_parameters)
end

# To enable root element in JSON for ActiveRecord objects.
# ActiveSupport.on_load(:active_record) do
# self.include_root_in_json = true
# end
Empty file added lib/assets/.keep
Empty file.
Empty file added lib/tasks/.keep
Empty file.
Loading

0 comments on commit 83b453b

Please sign in to comment.