diff options
author | Benoit Daloze <eregontp@gmail.com> | 2019-08-04 14:52:15 +0200 |
---|---|---|
committer | SHIBATA Hiroshi <hsbt@ruby-lang.org> | 2019-08-16 14:30:23 +0900 |
commit | 2b0f3aa095a410902b9b2e4fb14f909e0630c1a1 (patch) | |
tree | 6901f30fc32837107c3fb1771a49ec9e3cde93e6 /lib | |
parent | 6711343d5a630cc857f0fa503b403edb68415f48 (diff) | |
download | ruby-2b0f3aa095a410902b9b2e4fb14f909e0630c1a1.tar.gz |
[bundler/bundler] Use the standard RUBY_ENGINE_VERSION instead of JRUBY_VERSION
* RUBY_ENGINE and RUBY_ENGINE_VERSION are defined on every modern Ruby.
* There is no such constant as TRUFFLERUBY_VERSION or RBX_VERSION.
https://github.com/bundler/bundler/commit/f9d910403b
Diffstat (limited to 'lib')
-rw-r--r-- | lib/bundler/ruby_version.rb | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/lib/bundler/ruby_version.rb b/lib/bundler/ruby_version.rb index b981cba21d..7e403ce6fc 100644 --- a/lib/bundler/ruby_version.rb +++ b/lib/bundler/ruby_version.rb @@ -103,18 +103,8 @@ module Bundler def self.system ruby_engine = RUBY_ENGINE.dup - # :sob: mocking RUBY_VERSION breaks stuff on 1.8.7 ruby_version = ENV.fetch("BUNDLER_SPEC_RUBY_VERSION") { RUBY_VERSION }.dup - ruby_engine_version = case ruby_engine - when "ruby" - ruby_version - when "rbx" - Rubinius::VERSION.dup - when "jruby" - JRUBY_VERSION.dup - else - RUBY_ENGINE_VERSION.dup - end + ruby_engine_version = RUBY_ENGINE_VERSION.dup patchlevel = RUBY_PATCHLEVEL.to_s @ruby_version ||= RubyVersion.new(ruby_version, patchlevel, ruby_engine, ruby_engine_version) |