summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenoit Daloze <eregontp@gmail.com>2017-12-04 12:04:07 +0100
committerBenoit Daloze <eregontp@gmail.com>2018-09-09 16:38:22 +0200
commit455bfe1c831a1cb4705420a46402386f03558540 (patch)
treecbd6eef3ab70cc37987c72ac2d928c2d1a7afb04
parent7c49a211d86bbbe66528a994db6bf5530621aaf8 (diff)
downloadbundler-455bfe1c831a1cb4705420a46402386f03558540.tar.gz
Add TruffleRuby to the list of engines in Bundler
-rw-r--r--lib/bundler/current_ruby.rb8
1 files changed, 7 insertions, 1 deletions
diff --git a/lib/bundler/current_ruby.rb b/lib/bundler/current_ruby.rb
index 220d638b87..d5efaad6c5 100644
--- a/lib/bundler/current_ruby.rb
+++ b/lib/bundler/current_ruby.rb
@@ -32,11 +32,13 @@ module Bundler
mswin64
rbx
ruby
+ truffleruby
x64_mingw
].freeze
def ruby?
- !mswin? && (!defined?(RUBY_ENGINE) || RUBY_ENGINE == "ruby" || RUBY_ENGINE == "rbx" || RUBY_ENGINE == "maglev")
+ !mswin? && (!defined?(RUBY_ENGINE) || RUBY_ENGINE == "ruby" ||
+ RUBY_ENGINE == "rbx" || RUBY_ENGINE == "maglev" || RUBY_ENGINE == "truffleruby")
end
def mri?
@@ -55,6 +57,10 @@ module Bundler
defined?(RUBY_ENGINE) && RUBY_ENGINE == "maglev"
end
+ def truffleruby?
+ defined?(RUBY_ENGINE) && RUBY_ENGINE == "truffleruby"
+ end
+
def mswin?
Bundler::WINDOWS
end