Skip to content

Commit 493e667

Browse files
committed
Update rails to version 4.2.0.rc1
1 parent 2d15d0e commit 493e667

File tree

17 files changed

+129
-79
lines changed

17 files changed

+129
-79
lines changed

.gitignore

+2-1
Original file line numberDiff line numberDiff line change
@@ -16,5 +16,6 @@
1616
/db/*.sqlite3-journal
1717

1818
# Ignore all logfiles and tempfiles.
19-
/log/*.log
19+
/log/*
20+
!/log/.keep
2021
/tmp

Gemfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
source 'https://rubygems.org'
22
ruby '2.2.0'
33

4-
gem 'rails', '~> 4.1.8'
4+
gem 'rails', '~> 4.2.0.rc1'
55

66
gem 'arel'
77
gem 'devise'

Gemfile.lock

+57-35
Original file line numberDiff line numberDiff line change
@@ -1,34 +1,43 @@
11
GEM
22
remote: https://rubygems.org/
33
specs:
4-
actionmailer (4.1.8)
5-
actionpack (= 4.1.8)
6-
actionview (= 4.1.8)
4+
actionmailer (4.2.0.rc1)
5+
actionpack (= 4.2.0.rc1)
6+
actionview (= 4.2.0.rc1)
7+
activejob (= 4.2.0.rc1)
78
mail (~> 2.5, >= 2.5.4)
8-
actionpack (4.1.8)
9-
actionview (= 4.1.8)
10-
activesupport (= 4.1.8)
11-
rack (~> 1.5.2)
9+
rails-dom-testing (~> 1.0, >= 1.0.5)
10+
actionpack (4.2.0.rc1)
11+
actionview (= 4.2.0.rc1)
12+
activesupport (= 4.2.0.rc1)
13+
rack (~> 1.6.0.beta2)
1214
rack-test (~> 0.6.2)
13-
actionview (4.1.8)
14-
activesupport (= 4.1.8)
15+
rails-dom-testing (~> 1.0, >= 1.0.5)
16+
rails-html-sanitizer (~> 1.0, >= 1.0.1)
17+
actionview (4.2.0.rc1)
18+
activesupport (= 4.2.0.rc1)
1519
builder (~> 3.1)
1620
erubis (~> 2.7.0)
17-
activemodel (4.1.8)
18-
activesupport (= 4.1.8)
21+
rails-dom-testing (~> 1.0, >= 1.0.5)
22+
rails-html-sanitizer (~> 1.0, >= 1.0.1)
23+
activejob (4.2.0.rc1)
24+
activesupport (= 4.2.0.rc1)
25+
globalid (>= 0.3.0)
26+
activemodel (4.2.0.rc1)
27+
activesupport (= 4.2.0.rc1)
1928
builder (~> 3.1)
20-
activerecord (4.1.8)
21-
activemodel (= 4.1.8)
22-
activesupport (= 4.1.8)
23-
arel (~> 5.0.0)
24-
activesupport (4.1.8)
25-
i18n (~> 0.6, >= 0.6.9)
29+
activerecord (4.2.0.rc1)
30+
activemodel (= 4.2.0.rc1)
31+
activesupport (= 4.2.0.rc1)
32+
arel (~> 6.0)
33+
activesupport (4.2.0.rc1)
34+
i18n (>= 0.7.0.beta1, < 0.8)
2635
json (~> 1.7, >= 1.7.7)
2736
minitest (~> 5.1)
2837
thread_safe (~> 0.1)
2938
tzinfo (~> 1.1)
3039
addressable (2.3.6)
31-
arel (5.0.1.20140414130214)
40+
arel (6.0.0)
3241
ast (2.0.0)
3342
astrolabe (1.3.0)
3443
parser (>= 2.2.0.pre.3, < 3.0)
@@ -65,11 +74,13 @@ GEM
6574
railties (>= 3.2, < 5.0)
6675
geokit (1.9.0)
6776
multi_json (>= 1.3.2)
77+
globalid (0.3.0)
78+
activesupport (>= 4.1.0)
6879
haml (4.0.5)
6980
tilt
7081
hike (1.2.3)
7182
http_accept_language (2.0.2)
72-
i18n (0.6.11)
83+
i18n (0.7.0.beta1)
7384
jquery-rails (3.1.2)
7485
railties (>= 3.0, < 5.0)
7586
thor (>= 0.14, < 2.0)
@@ -79,6 +90,8 @@ GEM
7990
kaminari (0.16.1)
8091
actionpack (>= 3.0.0)
8192
activesupport (>= 3.0.0)
93+
loofah (2.0.1)
94+
nokogiri (>= 1.5.9)
8295
mail (2.6.3)
8396
mime-types (>= 1.16, < 3)
8497
method_source (0.8.2)
@@ -102,22 +115,31 @@ GEM
102115
slop (~> 3.4)
103116
puma (2.10.2)
104117
rack (>= 1.1, < 2.0)
105-
rack (1.5.2)
118+
rack (1.6.0.beta2)
106119
rack-pjax (0.8.0)
107120
nokogiri (~> 1.5)
108121
rack (~> 1.1)
109122
rack-test (0.6.2)
110123
rack (>= 1.0)
111-
rails (4.1.8)
112-
actionmailer (= 4.1.8)
113-
actionpack (= 4.1.8)
114-
actionview (= 4.1.8)
115-
activemodel (= 4.1.8)
116-
activerecord (= 4.1.8)
117-
activesupport (= 4.1.8)
124+
rails (4.2.0.rc1)
125+
actionmailer (= 4.2.0.rc1)
126+
actionpack (= 4.2.0.rc1)
127+
actionview (= 4.2.0.rc1)
128+
activejob (= 4.2.0.rc1)
129+
activemodel (= 4.2.0.rc1)
130+
activerecord (= 4.2.0.rc1)
131+
activesupport (= 4.2.0.rc1)
118132
bundler (>= 1.3.0, < 2.0)
119-
railties (= 4.1.8)
120-
sprockets-rails (~> 2.0)
133+
railties (= 4.2.0.rc1)
134+
sprockets-rails
135+
rails-deprecated_sanitizer (1.0.3)
136+
activesupport (>= 4.2.0.alpha)
137+
rails-dom-testing (1.0.5)
138+
activesupport (>= 4.2.0.beta, < 5.0)
139+
nokogiri (~> 1.6.0)
140+
rails-deprecated_sanitizer (>= 1.0.1)
141+
rails-html-sanitizer (1.0.1)
142+
loofah (~> 2.0)
121143
rails_12factor (0.0.3)
122144
rails_serve_static_assets
123145
rails_stdout_logging
@@ -137,16 +159,16 @@ GEM
137159
sass-rails (~> 4.0)
138160
rails_serve_static_assets (0.0.2)
139161
rails_stdout_logging (0.0.3)
140-
railties (4.1.8)
141-
actionpack (= 4.1.8)
142-
activesupport (= 4.1.8)
162+
railties (4.2.0.rc1)
163+
actionpack (= 4.2.0.rc1)
164+
activesupport (= 4.2.0.rc1)
143165
rake (>= 0.8.7)
144166
thor (>= 0.18.1, < 2.0)
145167
rainbow (2.0.0)
146168
rake (10.4.0)
147169
remotipart (1.2.1)
148-
responders (1.1.2)
149-
railties (>= 3.2, < 4.2)
170+
responders (2.0.2)
171+
railties (>= 4.2.0.alpha, < 5)
150172
rest-client (1.7.2)
151173
mime-types (>= 1.16, < 3.0)
152174
netrc (~> 0.7)
@@ -217,7 +239,7 @@ DEPENDENCIES
217239
pg
218240
pry
219241
puma
220-
rails (~> 4.1.8)
242+
rails (~> 4.2.0.rc1)
221243
rails_12factor
222244
rails_admin
223245
rubocop

app/assets/javascripts/application.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
// listed below.
33
//
44
// Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,
5-
// or vendor/assets/javascripts of plugins, if any, can be referenced here using a relative path.
5+
// or any plugin's vendor/assets/javascripts directory can be referenced here using a relative path.
66
//
77
// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
88
// compiled file.

app/assets/stylesheets/application.css

+2-2
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,13 @@
33
* listed below.
44
*
55
* Any CSS and SCSS file within this directory, lib/assets/stylesheets, vendor/assets/stylesheets,
6-
* or vendor/assets/stylesheets of plugins, if any, can be referenced here using a relative path.
6+
* or any plugin's vendor/assets/stylesheets directory can be referenced here using a relative path.
77
*
88
* You're free to add application-wide styles to this file and they'll appear at the bottom of the
99
* compiled file so the styles you add here take precedence over styles defined in any styles
1010
* defined in the other CSS/SCSS files in this directory. It is generally better to create a new
1111
* file per style scope.
1212
*
13-
*= require_self
1413
*= require_tree .
14+
*= require_self
1515
*/

bin/rails

+1-5
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,4 @@
11
#!/usr/bin/env ruby
2-
begin
3-
load File.expand_path("../spring", __FILE__)
4-
rescue LoadError
5-
end
6-
APP_PATH = File.expand_path('../../config/application', __FILE__)
2+
APP_PATH = File.expand_path('../../config/application', __FILE__)
73
require_relative '../config/boot'
84
require 'rails/commands'

bin/rake

-4
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,4 @@
11
#!/usr/bin/env ruby
2-
begin
3-
load File.expand_path("../spring", __FILE__)
4-
rescue LoadError
5-
end
62
require_relative '../config/boot'
73
require 'rake'
84
Rake.application.run

bin/setup

+29
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
#!/usr/bin/env ruby
2+
require 'pathname'
3+
4+
# path to your application root.
5+
APP_ROOT = Pathname.new File.expand_path('../../', __FILE__)
6+
7+
Dir.chdir APP_ROOT do
8+
# This script is a starting point to setup your application.
9+
# Add necessary setup steps to this file:
10+
11+
puts "== Installing dependencies =="
12+
system "gem install bundler --conservative"
13+
system "bundle check || bundle install"
14+
15+
# puts "\n== Copying sample files =="
16+
# unless File.exist?("config/database.yml")
17+
# system "cp config/database.yml.sample config/database.yml"
18+
# end
19+
20+
puts "\n== Preparing database =="
21+
system "bin/rake db:setup"
22+
23+
puts "\n== Removing old logs and tempfiles =="
24+
system "rm -f log/*"
25+
system "rm -rf tmp/cache"
26+
27+
puts "\n== Restarting application server =="
28+
system "touch tmp/restart.txt"
29+
end

config.ru

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
# This file is used by Rack-based servers to start the application.
22

3-
require ::File.expand_path('../config/environment', __FILE__)
3+
require ::File.expand_path('../config/environment', __FILE__)
44
run Rails.application

config/application.rb

+3
Original file line numberDiff line numberDiff line change
@@ -19,5 +19,8 @@ class Application < Rails::Application
1919
# The default locale is :en and all translations from config/locales/*.rb,yml are auto loaded.
2020
# config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s]
2121
# config.i18n.default_locale = :de
22+
23+
# Do not swallow errors in after_commit/after_rollback callbacks.
24+
config.active_record.raise_in_transactional_callbacks = true
2225
end
2326
end

config/boot.rb

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
# Set up gems listed in the Gemfile.
21
ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile', __FILE__)
32

4-
require 'bundler/setup' if File.exist?(ENV['BUNDLE_GEMFILE'])
3+
require 'bundler/setup' # Set up gems listed in the Gemfile.

config/environments/development.rb

+4
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,10 @@
2828
# number of complex assets.
2929
config.assets.debug = true
3030

31+
# Asset digests allow you to set far-future HTTP expiration dates on all assets,
32+
# yet still be able to expire them through the digest params.
33+
config.assets.digest = true
34+
3135
# Adds additional error checking when serving assets at runtime.
3236
# Checks for improperly declared sprockets dependencies.
3337
# Raises helpful error messages.

config/environments/production.rb

+12-14
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,11 @@
1616

1717
# Enable Rack::Cache to put a simple HTTP cache in front of your application
1818
# Add `rack-cache` to your Gemfile before enabling this.
19-
# For large-scale production use, consider using a caching reverse proxy like nginx, varnish or squid.
19+
# For large-scale production use, consider using a caching reverse proxy like
20+
# NGINX, varnish or squid.
2021
# config.action_dispatch.rack_cache = true
2122

22-
# Disable Rails's static asset server (Apache or nginx will already do this).
23+
# Disable Rails's static asset server (Apache or NGINX will already do this).
2324
config.serve_static_assets = false
2425

2526
# Compress JavaScripts and CSS.
@@ -29,21 +30,22 @@
2930
# Do not fallback to assets pipeline if a precompiled asset is missed.
3031
config.assets.compile = false
3132

32-
# Generate digests for assets URLs.
33+
# Asset digests allow you to set far-future HTTP expiration dates on all assets,
34+
# yet still be able to expire them through the digest params.
3335
config.assets.digest = true
3436

35-
# Version of your assets, change this if you want to expire all your assets.
36-
config.assets.version = '1.0'
37+
# `config.assets.precompile` and `config.assets.version` have moved to config/initializers/assets.rb
3738

3839
# Specifies the header that your server uses for sending files.
39-
# config.action_dispatch.x_sendfile_header = "X-Sendfile" # for apache
40-
# config.action_dispatch.x_sendfile_header = 'X-Accel-Redirect' # for nginx
40+
# config.action_dispatch.x_sendfile_header = 'X-Sendfile' # for Apache
41+
# config.action_dispatch.x_sendfile_header = 'X-Accel-Redirect' # for NGINX
4142

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

45-
# Set to :debug to see everything in the log.
46-
config.log_level = :info
46+
# Use the lowest log level to ensure availability of diagnostic information
47+
# when problems arise.
48+
config.log_level = :debug
4749

4850
# Prepend all log lines with the following tags.
4951
# config.log_tags = [ :subdomain, :uuid ]
@@ -55,11 +57,7 @@
5557
# config.cache_store = :mem_cache_store
5658

5759
# Enable serving of images, stylesheets, and JavaScripts from an asset server.
58-
# config.action_controller.asset_host = "http://assets.example.com"
59-
60-
# Precompile additional assets.
61-
# application.js, application.css, and all non-JS/CSS in app/assets folder are already added.
62-
# config.assets.precompile += %w( search.js )
60+
# config.action_controller.asset_host = 'http://assets.example.com'
6361

6462
# Ignore bad email addresses and do not raise email delivery errors.
6563
# Set this to true and configure the email server for immediate delivery to raise delivery errors.

config/environments/test.rb

+3
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,9 @@
3232
config.action_mailer.delivery_method = :test
3333
config.action_mailer.default_url_options = {host: 'localhost:3000'}
3434

35+
# Randomize the order test cases are executed
36+
config.active_support.test_order = :random
37+
3538
# Print deprecation notices to the stderr.
3639
config.active_support.deprecation = :stderr
3740

config/initializers/assets.rb

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# Be sure to restart your server when you modify this file.
2+
3+
# Version of your assets, change this if you want to expire all your assets.
4+
Rails.application.config.assets.version = '1.0'
5+
6+
# Add additional assets to the asset load path
7+
# Rails.application.config.assets.paths << Emoji.images_path
8+
9+
# Precompile additional assets.
10+
# application.js, application.css, and all non-JS/CSS in app/assets folder are already added.
11+
# Rails.application.config.assets.precompile += %w( search.js )

config/initializers/session_store.rb

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
# Be sure to restart your server when you modify this file.
22

3-
Rails.application.config.session_store :cookie_store, key: '_adopt-a-hydrant_session'
3+
Rails.application.config.session_store :cookie_store, key: '_adopt-a-thing_session'

test/performance/browsing_test.rb

-12
This file was deleted.

0 commit comments

Comments
 (0)