diff options
author | David RodrÃguez <[email protected]> | 2021-02-01 16:17:16 +0100 |
---|---|---|
committer | Hiroshi SHIBATA <[email protected]> | 2021-03-08 13:47:35 +0900 |
commit | 53468cc11147b0d285fc376fc546b677dad600ca (patch) | |
tree | eb9c97f544d089be2d324126b025b11f41a22c90 /lib/bundler/plugin | |
parent | 2ab6b7a7516e1b2c48a66ce513afabb62d101461 (diff) |
Sync latest development version of bundler & rubygems
Notes
Notes:
Merged: https://github.com/ruby/ruby/pull/4143
Diffstat (limited to 'lib/bundler/plugin')
-rw-r--r-- | lib/bundler/plugin/installer.rb | 18 | ||||
-rw-r--r-- | lib/bundler/plugin/source_list.rb | 4 |
2 files changed, 12 insertions, 10 deletions
diff --git a/lib/bundler/plugin/installer.rb b/lib/bundler/plugin/installer.rb index 26cec4f18c..980b0e29b8 100644 --- a/lib/bundler/plugin/installer.rb +++ b/lib/bundler/plugin/installer.rb @@ -16,15 +16,13 @@ module Bundler version = options[:version] || [">= 0"] - Bundler.settings.temporary(:disable_multisource => false) do - if options[:git] - install_git(names, version, options) - elsif options[:local_git] - install_local_git(names, version, options) - else - sources = options[:source] || Bundler.rubygems.sources - install_rubygems(names, version, sources) - end + if options[:git] + install_git(names, version, options) + elsif options[:local_git] + install_local_git(names, version, options) + else + sources = options[:source] || Bundler.rubygems.sources + install_rubygems(names, version, sources) end end @@ -79,7 +77,7 @@ module Bundler source_list = SourceList.new source_list.add_git_source(git_source_options) if git_source_options - source_list.add_rubygems_source("remotes" => rubygems_source) if rubygems_source + source_list.global_rubygems_source = rubygems_source if rubygems_source deps = names.map {|name| Dependency.new name, version } diff --git a/lib/bundler/plugin/source_list.rb b/lib/bundler/plugin/source_list.rb index b90a331d28..547661cf2f 100644 --- a/lib/bundler/plugin/source_list.rb +++ b/lib/bundler/plugin/source_list.rb @@ -17,6 +17,10 @@ module Bundler path_sources + git_sources + rubygems_sources + [metadata_source] end + def default_source + git_sources.first || global_rubygems_source + end + private def rubygems_aggregate_class |