diff options
author | Samuel Giddins <segiddins@segiddins.me> | 2016-07-19 17:01:51 -0500 |
---|---|---|
committer | Samuel Giddins <segiddins@segiddins.me> | 2016-07-20 09:35:41 -0500 |
commit | 6e377a1cb710e8ab699b5f4358445a28355de0e6 (patch) | |
tree | 74026511f214fe94a8a1ba343acca4d8f58102f3 | |
parent | c476ee2672b506f7f8909cd44ba4111da4c2b5c2 (diff) | |
download | bundler-seg-cleanup.tar.gz |
[RubyGems] Avoid warning for Installer.new with a pathseg-cleanup
-rw-r--r-- | lib/bundler/rubygems_gem_installer.rb | 6 | ||||
-rw-r--r-- | lib/bundler/source/rubygems.rb | 2 |
2 files changed, 7 insertions, 1 deletions
diff --git a/lib/bundler/rubygems_gem_installer.rb b/lib/bundler/rubygems_gem_installer.rb index 43637e1e60..e18f46268b 100644 --- a/lib/bundler/rubygems_gem_installer.rb +++ b/lib/bundler/rubygems_gem_installer.rb @@ -3,6 +3,12 @@ require "rubygems/installer" module Bundler class RubyGemsGemInstaller < Gem::Installer + unless respond_to?(:at) + def self.at(*args) + new(*args) + end + end + def check_executable_overwrite(filename) # Bundler needs to install gems regardless of binstub overwriting end diff --git a/lib/bundler/source/rubygems.rb b/lib/bundler/source/rubygems.rb index d9606e7087..aedad7086d 100644 --- a/lib/bundler/source/rubygems.rb +++ b/lib/bundler/source/rubygems.rb @@ -134,7 +134,7 @@ module Bundler installed_spec = nil Bundler.rubygems.preserve_paths do - installed_spec = Bundler::RubyGemsGemInstaller.new( + installed_spec = Bundler::RubyGemsGemInstaller.at( path, :install_dir => install_path.to_s, :bin_dir => bin_path.to_s, |