Class: Bundler::CurrentRuby
Relationships & Source Files | |
Inherits: | Object |
Defined in: | lib/bundler/current_ruby.rb |
Constant Summary
-
KNOWN_MAJOR_VERSIONS =
# File 'lib/bundler/current_ruby.rb', line 29KNOWN_MINOR_VERSIONS.map {|v| v.split(".", 2).first }.uniq.freeze
-
KNOWN_MINOR_VERSIONS =
# File 'lib/bundler/current_ruby.rb', line 12%w[ 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 3.0 3.1 3.2 3.3 ].freeze
-
KNOWN_PLATFORMS =
# File 'lib/bundler/current_ruby.rb', line 31%w[ jruby maglev mingw mri mswin mswin64 rbx ruby truffleruby windows x64_mingw ].freeze
Instance Attribute Summary
- #jruby? ⇒ Boolean readonly
- #maglev? ⇒ Boolean readonly
-
#mingw?
readonly
Alias for #windows?.
- #mri? ⇒ Boolean readonly
-
#mswin64?
readonly
Alias for #windows?.
-
#mswin?
readonly
Alias for #windows?.
- #rbx? ⇒ Boolean readonly
- #ruby? ⇒ Boolean readonly
- #truffleruby? ⇒ Boolean readonly
- #windows? ⇒ Boolean (also: #mswin?, #mswin64?, #mingw?, #x64_mingw?) readonly
-
#x64_mingw?
readonly
Alias for #windows?.
Instance Attribute Details
#jruby? ⇒ Boolean
(readonly)
[ GitHub ]
# File 'lib/bundler/current_ruby.rb', line 59
def jruby? RUBY_ENGINE == "jruby" end
#maglev? ⇒ Boolean
(readonly)
[ GitHub ]
# File 'lib/bundler/current_ruby.rb', line 63
def maglev? RUBY_ENGINE == "maglev" end
#mingw? (readonly)
Alias for #windows?.
# File 'lib/bundler/current_ruby.rb', line 76
alias_method :mingw?, :windows?
#mri? ⇒ Boolean
(readonly)
[ GitHub ]
# File 'lib/bundler/current_ruby.rb', line 51
def mri? !windows? && RUBY_ENGINE == "ruby" end
#mswin64? (readonly)
Alias for #windows?.
# File 'lib/bundler/current_ruby.rb', line 75
alias_method :mswin64?, :windows?
#mswin? (readonly)
Alias for #windows?.
# File 'lib/bundler/current_ruby.rb', line 74
alias_method :mswin?, :windows?
#rbx? ⇒ Boolean
(readonly)
[ GitHub ]
# File 'lib/bundler/current_ruby.rb', line 55
def rbx? ruby? && RUBY_ENGINE == "rbx" end
#ruby? ⇒ Boolean
(readonly)
[ GitHub ]
# File 'lib/bundler/current_ruby.rb', line 45
def ruby? return true if Bundler::GemHelpers.generic_local_platform_is_ruby? !windows? && (RUBY_ENGINE == "ruby" || RUBY_ENGINE == "rbx" || RUBY_ENGINE == "maglev" || RUBY_ENGINE == "truffleruby") end
#truffleruby? ⇒ Boolean
(readonly)
[ GitHub ]
# File 'lib/bundler/current_ruby.rb', line 67
def truffleruby? RUBY_ENGINE == "truffleruby" end
#windows? ⇒ Boolean
(readonly)
Also known as: #mswin?, #mswin64?, #mingw?, #x64_mingw?
[ GitHub ]
# File 'lib/bundler/current_ruby.rb', line 71
def windows? Gem.win_platform? end
#x64_mingw? (readonly)
Alias for #windows?.
# File 'lib/bundler/current_ruby.rb', line 77
alias_method :x64_mingw?, :windows?