diff options
author | Jeremy Kemper <jeremy@bitsweat.net> | 2010-06-11 11:02:47 -0700 |
---|---|---|
committer | Jeremy Kemper <jeremy@bitsweat.net> | 2010-06-11 11:02:47 -0700 |
commit | 1a5654851e23b081c331bb3a7e0d0ffc2c2d6e51 (patch) | |
tree | ce99d2dcaf81b64a9d0b3119ab59fb8fa0e99e35 /railties/lib | |
parent | acad3ba848790c388062bb4ef300e4321e7ad89f (diff) | |
download | rails-1a5654851e23b081c331bb3a7e0d0ffc2c2d6e51.tar.gz rails-1a5654851e23b081c331bb3a7e0d0ffc2c2d6e51.tar.bz2 rails-1a5654851e23b081c331bb3a7e0d0ffc2c2d6e51.zip |
Single ruby version requirement message
Diffstat (limited to 'railties/lib')
-rw-r--r-- | railties/lib/rails.rb | 3 | ||||
-rw-r--r-- | railties/lib/rails/ruby_version_check.rb | 12 |
2 files changed, 5 insertions, 10 deletions
diff --git a/railties/lib/rails.rb b/railties/lib/rails.rb index be486ef2ac..7d476574e1 100644 --- a/railties/lib/rails.rb +++ b/railties/lib/rails.rb @@ -1,3 +1,5 @@ +require 'rails/ruby_version_check' + require 'pathname' require 'active_support' @@ -8,7 +10,6 @@ require 'rails/application' require 'rails/version' require 'rails/deprecation' require 'rails/log_subscriber' -require 'rails/ruby_version_check' require 'active_support/railtie' require 'action_dispatch/railtie' diff --git a/railties/lib/rails/ruby_version_check.rb b/railties/lib/rails/ruby_version_check.rb index 3b37c41c29..994df17e65 100644 --- a/railties/lib/rails/ruby_version_check.rb +++ b/railties/lib/rails/ruby_version_check.rb @@ -1,16 +1,10 @@ -min_release = "1.8.7" ruby_release = "#{RUBY_VERSION} (#{RUBY_RELEASE_DATE})" -if ruby_release < min_release +if ruby_release < '1.8.7' || (ruby_release > '1.8' && ruby_release < '1.9.2') abort <<-end_message - Rails requires Ruby version #{min_release} or later. + Rails 3 requires Ruby 1.8.7 or 1.9.2. + You're running #{ruby_release}; please upgrade to continue. end_message -elsif RUBY_VERSION == '1.9.1' - abort <<-EOS - - Rails 3 does not work with Ruby 1.9.1. Please upgrade to 1.9.2. - - EOS end |