Skip to content

Commit ad60813

Browse files
author
Sam Phippen
committed
Further version checking fixes
1 parent 66cd513 commit ad60813

File tree

1 file changed

+6
-21
lines changed

1 file changed

+6
-21
lines changed

Gemfile-rails-dependencies

Lines changed: 6 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -13,37 +13,22 @@ when /master/
1313
gem 'i18n', :git => 'https://github.com/svenfuchs/i18n.git', :branch => 'master'
1414
gem 'sprockets', :git => 'https://github.com/rails/sprockets.git', :branch => 'master'
1515
gem 'sprockets-rails', :git => 'https://github.com/rails/sprockets-rails.git', :branch => 'master'
16-
if RUBY_VERSION >= "2.2"
17-
gem 'puma', :git => 'https://github.com/puma/puma', :branch => 'master'
18-
end
16+
gem 'puma', :git => 'https://github.com/puma/puma', :branch => 'master'
1917
when /stable$/
2018
gem_list = %w[rails railties actionmailer actionpack activerecord activesupport]
21-
gem_list << 'activejob' if version > '4-1-stable'
22-
gem_list << 'actionview' if version > '4-0-stable'
23-
if RUBY_VERSION >= "2.2"
24-
gem_list << 'puma' if version > '5-0-stable'
25-
end
19+
gem_list << 'activejob' if version >= '4-2-stable'
20+
gem_list << 'actionview' if version >= '4-2-stable'
21+
gem_list << 'puma' if version > '5-0-stable'
2622

2723
gem_list.each do |rails_gem|
2824
gem rails_gem, :git => "https://github.com/rails/rails.git", :branch => version
2925
end
3026
when nil, false, ""
31-
if RUBY_VERSION < '1.9.3'
32-
# Rails 4+ requires 1.9.3+, so on earlier versions default to the last 3.x release.
33-
gem "rails", "~> 3.2.17"
34-
elsif RUBY_VERSION < '2.2.0'
35-
# Rails 5+ requires 2.2+, so on earlier versions default to the last 4.x release.
36-
gem "rails", "~> 4.2.0"
37-
else
38-
gem "rails", "~> 5.0.0"
39-
end
27+
gem "rails", "~> 5.0.0"
4028
else
4129
gem "rails", version
4230

43-
if version >= '5-1-stable' && RUBY_VERSION >= "2.2"
31+
if version >= '5-1-stable' && RUBY_VERSION >= "2.3"
4432
gem "puma"
4533
end
4634
end
47-
48-
gem "i18n", '< 0.7.0' if RUBY_VERSION < '1.9.3'
49-
gem "test-unit" if RUBY_VERSION >= '2.2.0' && version =~ /3[.-]2[.-]/

0 commit comments

Comments
 (0)