aboutsummaryrefslogtreecommitdiffstats
path: root/lib/bundler/installer/standalone.rb
diff options
context:
space:
mode:
authorDavid Rodríguez <deivid.rodriguez@riseup.net>2021-07-30 12:39:04 +0200
committerHiroshi SHIBATA <hsbt@ruby-lang.org>2021-08-31 19:06:14 +0900
commit3aa087d5335112268b2d1bc4b0690ca62de732bc (patch)
treeee7218c96a798e16d108019e3714d579547a2851 /lib/bundler/installer/standalone.rb
parent1d6551a02da866dc82866736cb216ce22dbd39d0 (diff)
downloadruby-3aa087d5335112268b2d1bc4b0690ca62de732bc.tar.gz
[rubygems/rubygems] Remove unnecessary `ruby_engine` local variable
Under some case, this variable might not end up being used, in which case running the script would print unused variable warnings. https://github.com/rubygems/rubygems/commit/a2d6392ada
Diffstat (limited to 'lib/bundler/installer/standalone.rb')
-rw-r--r--lib/bundler/installer/standalone.rb3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/bundler/installer/standalone.rb b/lib/bundler/installer/standalone.rb
index 10ccf7d281..15551080eb 100644
--- a/lib/bundler/installer/standalone.rb
+++ b/lib/bundler/installer/standalone.rb
@@ -12,7 +12,6 @@ module Bundler
end
File.open File.join(bundler_path, "setup.rb"), "w" do |file|
file.puts "require 'rbconfig'"
- file.puts "ruby_engine = RUBY_ENGINE"
file.puts "ruby_version = RbConfig::CONFIG[\"ruby_version\"]"
file.puts reverse_rubygems_kernel_mixin
paths.each do |path|
@@ -27,7 +26,7 @@ module Bundler
@specs.map do |spec|
next if spec.name == "bundler"
Array(spec.require_paths).map do |path|
- gem_path(path, spec).sub(version_dir, '#{ruby_engine}/#{ruby_version}')
+ gem_path(path, spec).sub(version_dir, '#{RUBY_ENGINE}/#{ruby_version}')
# This is a static string intentionally. It's interpolated at a later time.
end
end.flatten.compact