bundler 2.1.4 → 2.2.0.rc.1

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of bundler might be problematic. Click here for more details.

Files changed (130) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +806 -741
  3. data/README.md +6 -8
  4. data/bundler.gemspec +3 -3
  5. data/exe/bundle +3 -0
  6. data/lib/bundler.rb +15 -4
  7. data/lib/bundler/build_metadata.rb +2 -2
  8. data/lib/bundler/cli.rb +32 -11
  9. data/lib/bundler/cli/console.rb +1 -1
  10. data/lib/bundler/cli/gem.rb +83 -10
  11. data/lib/bundler/cli/info.rb +13 -3
  12. data/lib/bundler/cli/init.rb +1 -1
  13. data/lib/bundler/cli/install.rb +5 -14
  14. data/lib/bundler/cli/issue.rb +2 -2
  15. data/lib/bundler/cli/list.rb +11 -9
  16. data/lib/bundler/cli/outdated.rb +88 -65
  17. data/lib/bundler/cli/plugin.rb +10 -0
  18. data/lib/bundler/cli/pristine.rb +5 -0
  19. data/lib/bundler/definition.rb +32 -32
  20. data/lib/bundler/dependency.rb +0 -9
  21. data/lib/bundler/dsl.rb +1 -5
  22. data/lib/bundler/environment_preserver.rb +26 -2
  23. data/lib/bundler/errors.rb +1 -0
  24. data/lib/bundler/feature_flag.rb +0 -2
  25. data/lib/bundler/fetcher.rb +1 -0
  26. data/lib/bundler/friendly_errors.rb +4 -10
  27. data/lib/bundler/gem_helper.rb +17 -10
  28. data/lib/bundler/gem_version_promoter.rb +1 -1
  29. data/lib/bundler/injector.rb +14 -3
  30. data/lib/bundler/inline.rb +1 -1
  31. data/lib/bundler/installer.rb +29 -28
  32. data/lib/bundler/installer/gem_installer.rb +2 -2
  33. data/lib/bundler/installer/parallel_installer.rb +9 -9
  34. data/lib/bundler/lazy_specification.rb +16 -3
  35. data/lib/bundler/plugin.rb +26 -0
  36. data/lib/bundler/plugin/index.rb +9 -0
  37. data/lib/bundler/psyched_yaml.rb +0 -15
  38. data/lib/bundler/remote_specification.rb +4 -1
  39. data/lib/bundler/resolver.rb +31 -8
  40. data/lib/bundler/resolver/spec_group.rb +26 -5
  41. data/lib/bundler/rubygems_ext.rb +7 -8
  42. data/lib/bundler/rubygems_gem_installer.rb +1 -7
  43. data/lib/bundler/rubygems_integration.rb +3 -48
  44. data/lib/bundler/runtime.rb +2 -12
  45. data/lib/bundler/settings.rb +0 -3
  46. data/lib/bundler/shared_helpers.rb +1 -1
  47. data/lib/bundler/source/git.rb +4 -4
  48. data/lib/bundler/source/git/git_proxy.rb +53 -58
  49. data/lib/bundler/source/path.rb +5 -1
  50. data/lib/bundler/source/path/installer.rb +7 -9
  51. data/lib/bundler/source/rubygems.rb +11 -14
  52. data/lib/bundler/stub_specification.rb +16 -4
  53. data/lib/bundler/templates/newgem/CODE_OF_CONDUCT.md.tt +57 -47
  54. data/lib/bundler/templates/newgem/Gemfile.tt +9 -1
  55. data/lib/bundler/templates/newgem/Rakefile.tt +19 -5
  56. data/lib/bundler/templates/newgem/bin/console.tt +2 -0
  57. data/lib/bundler/templates/newgem/circleci/config.yml.tt +13 -0
  58. data/lib/bundler/templates/newgem/ext/newgem/extconf.rb.tt +2 -0
  59. data/lib/bundler/templates/newgem/github/workflows/main.yml.tt +18 -0
  60. data/lib/bundler/templates/newgem/gitlab-ci.yml.tt +9 -0
  61. data/lib/bundler/templates/newgem/lib/newgem.rb.tt +2 -0
  62. data/lib/bundler/templates/newgem/lib/newgem/version.rb.tt +2 -0
  63. data/lib/bundler/templates/newgem/newgem.gemspec.tt +6 -4
  64. data/lib/bundler/templates/newgem/rubocop.yml.tt +10 -0
  65. data/lib/bundler/templates/newgem/spec/newgem_spec.rb.tt +2 -0
  66. data/lib/bundler/templates/newgem/spec/spec_helper.rb.tt +2 -0
  67. data/lib/bundler/templates/newgem/test/{newgem_test.rb.tt → minitest/newgem_test.rb.tt} +2 -0
  68. data/lib/bundler/templates/newgem/test/{test_helper.rb.tt → minitest/test_helper.rb.tt} +2 -0
  69. data/lib/bundler/templates/newgem/test/test-unit/newgem_test.rb.tt +15 -0
  70. data/lib/bundler/templates/newgem/test/test-unit/test_helper.rb.tt +6 -0
  71. data/lib/bundler/vendor/net-http-persistent/lib/net/http/persistent.rb +75 -189
  72. data/lib/bundler/vendor/thor/lib/thor.rb +0 -7
  73. data/lib/bundler/vendor/thor/lib/thor/actions/create_link.rb +2 -1
  74. data/lib/bundler/vendor/thor/lib/thor/base.rb +9 -0
  75. data/lib/bundler/vendor/thor/lib/thor/version.rb +1 -1
  76. data/lib/bundler/version.rb +1 -1
  77. data/man/bundle-add.1 +1 -1
  78. data/man/bundle-add.1.txt +15 -15
  79. data/man/bundle-binstubs.1 +1 -1
  80. data/man/bundle-binstubs.1.txt +10 -10
  81. data/man/bundle-cache.1 +1 -1
  82. data/man/bundle-cache.1.txt +15 -15
  83. data/man/bundle-check.1 +1 -1
  84. data/man/bundle-check.1.txt +8 -8
  85. data/man/bundle-clean.1 +1 -1
  86. data/man/bundle-clean.1.txt +6 -6
  87. data/man/bundle-config.1 +3 -9
  88. data/man/bundle-config.1.txt +271 -272
  89. data/man/bundle-config.ronn +5 -9
  90. data/man/bundle-doctor.1 +1 -1
  91. data/man/bundle-doctor.1.txt +9 -9
  92. data/man/bundle-exec.1 +1 -1
  93. data/man/bundle-exec.1.txt +84 -81
  94. data/man/bundle-gem.1 +25 -3
  95. data/man/bundle-gem.1.txt +65 -39
  96. data/man/bundle-gem.ronn +30 -7
  97. data/man/bundle-info.1 +1 -1
  98. data/man/bundle-info.1.txt +2 -2
  99. data/man/bundle-init.1 +1 -1
  100. data/man/bundle-init.1.txt +9 -9
  101. data/man/bundle-inject.1 +1 -1
  102. data/man/bundle-inject.1.txt +4 -4
  103. data/man/bundle-install.1 +1 -1
  104. data/man/bundle-install.1.txt +169 -169
  105. data/man/bundle-list.1 +7 -7
  106. data/man/bundle-list.1.txt +12 -11
  107. data/man/bundle-list.ronn +6 -6
  108. data/man/bundle-lock.1 +1 -1
  109. data/man/bundle-lock.1.txt +28 -28
  110. data/man/bundle-open.1 +1 -1
  111. data/man/bundle-open.1.txt +3 -3
  112. data/man/bundle-outdated.1 +1 -1
  113. data/man/bundle-outdated.1.txt +34 -34
  114. data/man/bundle-platform.1 +1 -1
  115. data/man/bundle-platform.1.txt +16 -16
  116. data/man/bundle-pristine.1 +1 -1
  117. data/man/bundle-pristine.1.txt +8 -8
  118. data/man/bundle-remove.1 +1 -1
  119. data/man/bundle-remove.1.txt +9 -9
  120. data/man/bundle-show.1 +1 -1
  121. data/man/bundle-show.1.txt +8 -8
  122. data/man/bundle-update.1 +1 -1
  123. data/man/bundle-update.1.txt +149 -148
  124. data/man/bundle-viz.1 +1 -1
  125. data/man/bundle-viz.1.txt +11 -11
  126. data/man/bundle.1 +1 -1
  127. data/man/bundle.1.txt +31 -31
  128. data/man/gemfile.5 +1 -1
  129. data/man/gemfile.5.txt +218 -216
  130. metadata +14 -8
@@ -47,6 +47,32 @@ module Bundler
47
47
  Bundler.ui.error "Failed to install plugin #{name}: #{e.message}\n #{e.backtrace.join("\n ")}"
48
48
  end
49
49
 
50
+ # Uninstalls plugins by the given names
51
+ #
52
+ # @param [Array<String>] names the names of plugins to be uninstalled
53
+ def uninstall(names, options)
54
+ if names.empty? && !options[:all]
55
+ Bundler.ui.error "No plugins to uninstall. Specify at least 1 plugin to uninstall.\n"\
56
+ "Use --all option to uninstall all the installed plugins."
57
+ return
58
+ end
59
+
60
+ names = index.installed_plugins if options[:all]
61
+ if names.any?
62
+ names.each do |name|
63
+ if index.installed?(name)
64
+ Bundler.rm_rf(index.plugin_path(name))
65
+ index.unregister_plugin(name)
66
+ Bundler.ui.info "Uninstalled plugin #{name}"
67
+ else
68
+ Bundler.ui.error "Plugin #{name} is not installed \n"
69
+ end
70
+ end
71
+ else
72
+ Bundler.ui.info "No plugins installed"
73
+ end
74
+ end
75
+
50
76
  # List installed plugins and commands
51
77
  #
52
78
  def list
@@ -71,6 +71,15 @@ module Bundler
71
71
  raise
72
72
  end
73
73
 
74
+ def unregister_plugin(name)
75
+ @commands.delete_if {|_, v| v == name }
76
+ @sources.delete_if {|_, v| v == name }
77
+ @hooks.each {|_, plugin_names| plugin_names.delete(name) }
78
+ @plugin_paths.delete(name)
79
+ @load_paths.delete(name)
80
+ save_index
81
+ end
82
+
74
83
  # Path of default index file
75
84
  def index_file
76
85
  Plugin.root.join("index")
@@ -1,11 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- # Psych could be a gem, so try to ask for it
4
- begin
5
- gem "psych"
6
- rescue LoadError
7
- end if defined?(gem)
8
-
9
3
  # Psych could be in the stdlib
10
4
  # but it's too late if Syck is already loaded
11
5
  begin
@@ -26,12 +20,3 @@ module Bundler
26
20
  YamlLibrarySyntaxError = ::ArgumentError
27
21
  end
28
22
  end
29
-
30
- require_relative "deprecate"
31
- begin
32
- Bundler::Deprecate.skip_during do
33
- require "rubygems/safe_yaml"
34
- end
35
- rescue LoadError
36
- # it's OK if the file isn't there
37
- end
@@ -50,6 +50,8 @@ module Bundler
50
50
  # once the remote gem is downloaded, the backend specification will
51
51
  # be swapped out.
52
52
  def __swap__(spec)
53
+ raise APIResponseInvalidDependenciesError unless spec.dependencies.all? {|d| d.is_a?(Gem::Dependency) }
54
+
53
55
  SharedHelpers.ensure_same_dependencies(self, dependencies, spec.dependencies)
54
56
  @_remote_specification = spec
55
57
  end
@@ -76,7 +78,8 @@ module Bundler
76
78
  deps = method_missing(:dependencies)
77
79
 
78
80
  # allow us to handle when the specs dependencies are an array of array of string
79
- # see https://github.com/bundler/bundler/issues/5797
81
+ # in order to delay the crash to `#__swap__` where it results in a friendlier error
82
+ # see https://github.com/rubygems/bundler/issues/5797
80
83
  deps = deps.map {|d| d.is_a?(Gem::Dependency) ? d : Gem::Dependency.new(*d) }
81
84
 
82
85
  deps
@@ -75,12 +75,17 @@ module Bundler
75
75
  return unless debug?
76
76
  debug_info = yield
77
77
  debug_info = debug_info.inspect unless debug_info.is_a?(String)
78
- warn debug_info.split("\n").map {|s| " " * depth + s }
78
+ warn debug_info.split("\n").map {|s| "BUNDLER: " + " " * depth + s }
79
79
  end
80
80
 
81
81
  def debug?
82
82
  return @debug_mode if defined?(@debug_mode)
83
- @debug_mode = ENV["DEBUG_RESOLVER"] || ENV["DEBUG_RESOLVER_TREE"] || false
83
+ @debug_mode =
84
+ ENV["BUNDLER_DEBUG_RESOLVER"] ||
85
+ ENV["BUNDLER_DEBUG_RESOLVER_TREE"] ||
86
+ ENV["DEBUG_RESOLVER"] ||
87
+ ENV["DEBUG_RESOLVER_TREE"] ||
88
+ false
84
89
  end
85
90
 
86
91
  def before_resolution
@@ -146,7 +151,26 @@ module Bundler
146
151
  @gem_version_promoter.sort_versions(dependency, spec_groups)
147
152
  end
148
153
  end
149
- search.select {|sg| sg.for?(platform) }.each {|sg| sg.activate_platform!(platform) }
154
+ selected_sgs = []
155
+ search.each do |sg|
156
+ next unless sg.for?(platform)
157
+ # Add a spec group for "non platform specific spec" as the fallback
158
+ # spec group.
159
+ sg_ruby = sg.copy_for(Gem::Platform::RUBY)
160
+ selected_sgs << sg_ruby if sg_ruby
161
+ sg_all_platforms = nil
162
+ all_platforms = @platforms + [platform]
163
+ sorted_all_platforms = self.class.sort_platforms(all_platforms)
164
+ sorted_all_platforms.reverse_each do |other_platform|
165
+ if sg_all_platforms.nil?
166
+ sg_all_platforms = sg.copy_for(other_platform)
167
+ else
168
+ sg_all_platforms.activate_platform!(other_platform)
169
+ end
170
+ end
171
+ selected_sgs << sg_all_platforms
172
+ end
173
+ selected_sgs
150
174
  end
151
175
 
152
176
  def index_for(dependency)
@@ -183,9 +207,7 @@ module Bundler
183
207
  end
184
208
 
185
209
  def requirement_satisfied_by?(requirement, activated, spec)
186
- return false unless requirement.matches_spec?(spec) || spec.source.is_a?(Source::Gemspec)
187
- spec.activate_platform!(requirement.__platform) if !@platforms || @platforms.include?(requirement.__platform)
188
- true
210
+ requirement.matches_spec?(spec) || spec.source.is_a?(Source::Gemspec)
189
211
  end
190
212
 
191
213
  def relevant_sources_for_vertex(vertex)
@@ -223,8 +245,9 @@ module Bundler
223
245
  end
224
246
 
225
247
  def self.platform_sort_key(platform)
226
- return ["", "", ""] if Gem::Platform::RUBY == platform
227
- platform.to_a.map {|part| part || "" }
248
+ # Prefer specific platform to not specific platform
249
+ return ["99-LAST", "", "", ""] if Gem::Platform::RUBY == platform
250
+ ["00", *platform.to_a.map {|part| part || "" }]
228
251
  end
229
252
 
230
253
  private
@@ -9,6 +9,7 @@ module Bundler
9
9
  attr_accessor :ignores_bundler_dependencies
10
10
 
11
11
  def initialize(all_specs)
12
+ @all_specs = all_specs
12
13
  raise ArgumentError, "cannot initialize with an empty value" unless exemplary_spec = all_specs.first
13
14
  @name = exemplary_spec.name
14
15
  @version = exemplary_spec.version
@@ -28,7 +29,7 @@ module Bundler
28
29
  lazy_spec = LazySpecification.new(name, version, s.platform, source)
29
30
  lazy_spec.dependencies.replace s.dependencies
30
31
  lazy_spec
31
- end.compact
32
+ end.compact.uniq
32
33
  end
33
34
 
34
35
  def activate_platform!(platform)
@@ -37,13 +38,25 @@ module Bundler
37
38
  @activated_platforms << platform
38
39
  end
39
40
 
41
+ def copy_for(platform)
42
+ copied_sg = self.class.new(@all_specs)
43
+ copied_sg.ignores_bundler_dependencies = @ignores_bundler_dependencies
44
+ return nil unless copied_sg.for?(platform)
45
+ copied_sg.activate_platform!(platform)
46
+ copied_sg
47
+ end
48
+
49
+ def spec_for(platform)
50
+ @specs[platform]
51
+ end
52
+
40
53
  def for?(platform)
41
- spec = @specs[platform]
42
- !spec.nil?
54
+ !spec_for(platform).nil?
43
55
  end
44
56
 
45
57
  def to_s
46
- @to_s ||= "#{name} (#{version})"
58
+ activated_platforms_string = sorted_activated_platforms.join(", ")
59
+ "#{name} (#{version}) (#{activated_platforms_string})"
47
60
  end
48
61
 
49
62
  def dependencies_for_activated_platforms
@@ -58,6 +71,7 @@ module Bundler
58
71
  return unless other.is_a?(SpecGroup)
59
72
  name == other.name &&
60
73
  version == other.version &&
74
+ sorted_activated_platforms == other.sorted_activated_platforms &&
61
75
  source == other.source
62
76
  end
63
77
 
@@ -65,11 +79,18 @@ module Bundler
65
79
  return unless other.is_a?(SpecGroup)
66
80
  name.eql?(other.name) &&
67
81
  version.eql?(other.version) &&
82
+ sorted_activated_platforms.eql?(other.sorted_activated_platforms) &&
68
83
  source.eql?(other.source)
69
84
  end
70
85
 
71
86
  def hash
72
- to_s.hash ^ source.hash
87
+ name.hash ^ version.hash ^ sorted_activated_platforms.hash ^ source.hash
88
+ end
89
+
90
+ protected
91
+
92
+ def sorted_activated_platforms
93
+ @activated_platforms.sort_by(&:to_s)
73
94
  end
74
95
 
75
96
  private
@@ -47,14 +47,13 @@ module Gem
47
47
  full_require_paths
48
48
  end
49
49
 
50
- if method_defined?(:extension_dir)
51
- alias_method :rg_extension_dir, :extension_dir
52
- def extension_dir
53
- @bundler_extension_dir ||= if source.respond_to?(:extension_dir_name)
54
- File.expand_path(File.join(extensions_dir, source.extension_dir_name))
55
- else
56
- rg_extension_dir
57
- end
50
+ alias_method :rg_extension_dir, :extension_dir
51
+ def extension_dir
52
+ @bundler_extension_dir ||= if source.respond_to?(:extension_dir_name)
53
+ unique_extension_dir = [source.extension_dir_name, File.basename(full_gem_path)].uniq.join("-")
54
+ File.expand_path(File.join(extensions_dir, unique_extension_dir))
55
+ else
56
+ rg_extension_dir
58
57
  end
59
58
  end
60
59
 
@@ -4,12 +4,6 @@ require "rubygems/installer"
4
4
 
5
5
  module Bundler
6
6
  class RubyGemsGemInstaller < Gem::Installer
7
- unless respond_to?(:at)
8
- def self.at(*args)
9
- new(*args)
10
- end
11
- end
12
-
13
7
  def check_executable_overwrite(filename)
14
8
  # Bundler needs to install gems regardless of binstub overwriting
15
9
  end
@@ -20,7 +14,7 @@ module Bundler
20
14
 
21
15
  def build_extensions
22
16
  extension_cache_path = options[:bundler_extension_cache_path]
23
- return super unless extension_cache_path && extension_dir = Bundler.rubygems.spec_extension_dir(spec)
17
+ return super unless extension_cache_path && extension_dir = spec.extension_dir
24
18
 
25
19
  extension_dir = Pathname.new(extension_dir)
26
20
  build_complete = SharedHelpers.filesystem_access(extension_cache_path.join("gem.build_complete"), :read, &:file?)
@@ -102,11 +102,6 @@ module Bundler
102
102
  end.flatten(1)
103
103
  end
104
104
 
105
- def spec_extension_dir(spec)
106
- return unless spec.respond_to?(:extension_dir)
107
- spec.extension_dir
108
- end
109
-
110
105
  def stub_set_spec(stub, spec)
111
106
  stub.instance_variable_set(:@spec, spec)
112
107
  end
@@ -141,14 +136,10 @@ module Bundler
141
136
  end
142
137
 
143
138
  def inflate(obj)
144
- require "rubygems/util"
145
-
146
139
  Gem::Util.inflate(obj)
147
140
  end
148
141
 
149
142
  def correct_for_windows_path(path)
150
- require "rubygems/util"
151
-
152
143
  if Gem::Util.respond_to?(:correct_for_windows_path)
153
144
  Gem::Util.correct_for_windows_path(path)
154
145
  elsif path[0].chr == "/" && path[1].chr =~ /[a-z]/i && path[2].chr == ":"
@@ -223,11 +214,6 @@ module Bundler
223
214
  Gem.bin_path(gem, bin, ver)
224
215
  end
225
216
 
226
- def preserve_paths
227
- # this is a no-op outside of RubyGems 1.8
228
- yield
229
- end
230
-
231
217
  def loaded_gem_paths
232
218
  loaded_gem_paths = Gem.loaded_specs.map {|_, s| s.full_require_paths }
233
219
  loaded_gem_paths.flatten
@@ -265,8 +251,6 @@ module Bundler
265
251
  require "rubygems/security"
266
252
  require_relative "psyched_yaml"
267
253
  gem_from_path(path, security_policies[policy]).spec
268
- rescue Gem::Package::FormatError
269
- raise GemspecError, "Could not read gem at #{path}. It may be corrupted."
270
254
  rescue Exception, Gem::Exception, Gem::Security::Exception => e # rubocop:disable Lint/RescueException
271
255
  if e.is_a?(Gem::Security::Exception) ||
272
256
  e.message =~ /unknown trust policy|unsigned gem/i ||
@@ -346,7 +330,7 @@ module Bundler
346
330
  raise e
347
331
  end
348
332
 
349
- # backwards compatibility shim, see https://github.com/bundler/bundler/issues/5102
333
+ # backwards compatibility shim, see https://github.com/rubygems/bundler/issues/5102
350
334
  kernel_class.send(:public, :gem) if Bundler.feature_flag.setup_makes_kernel_gem_public?
351
335
  end
352
336
  end
@@ -443,35 +427,6 @@ module Bundler
443
427
  Gem.clear_paths
444
428
  end
445
429
 
446
- # This backports base_dir which replaces installation path
447
- # RubyGems 1.8+
448
- def backport_base_dir
449
- redefine_method(Gem::Specification, :base_dir) do
450
- return Gem.dir unless loaded_from
451
- File.dirname File.dirname loaded_from
452
- end
453
- end
454
-
455
- def backport_cache_file
456
- redefine_method(Gem::Specification, :cache_dir) do
457
- @cache_dir ||= File.join base_dir, "cache"
458
- end
459
-
460
- redefine_method(Gem::Specification, :cache_file) do
461
- @cache_file ||= File.join cache_dir, "#{full_name}.gem"
462
- end
463
- end
464
-
465
- def backport_spec_file
466
- redefine_method(Gem::Specification, :spec_dir) do
467
- @spec_dir ||= File.join base_dir, "specifications"
468
- end
469
-
470
- redefine_method(Gem::Specification, :spec_file) do
471
- @spec_file ||= File.join spec_dir, "#{full_name}.gemspec"
472
- end
473
- end
474
-
475
430
  def undo_replacements
476
431
  @replaced_methods.each do |(sym, klass), method|
477
432
  redefine_method(klass, sym, method)
@@ -602,10 +557,10 @@ module Bundler
602
557
 
603
558
  def backport_ext_builder_monitor
604
559
  # So we can avoid requiring "rubygems/ext" in its entirety
605
- Gem.module_eval <<-RB, __FILE__, __LINE__ + 1
560
+ Gem.module_eval <<-RUBY, __FILE__, __LINE__ + 1
606
561
  module Ext
607
562
  end
608
- RB
563
+ RUBY
609
564
 
610
565
  require "rubygems/ext/builder"
611
566
 
@@ -43,14 +43,6 @@ module Bundler
43
43
  self
44
44
  end
45
45
 
46
- REQUIRE_ERRORS = [
47
- /^no such file to load -- (.+)$/i,
48
- /^Missing \w+ (?:file\s*)?([^\s]+.rb)$/i,
49
- /^Missing API definition file in (.+)$/i,
50
- /^cannot load such file -- (.+)$/i,
51
- /^dlopen\([^)]*\): Library not loaded: (.+)$/i,
52
- ].freeze
53
-
54
46
  def require(*groups)
55
47
  groups.map!(&:to_sym)
56
48
  groups = [:default] if groups.empty?
@@ -79,16 +71,14 @@ module Bundler
79
71
  end
80
72
  end
81
73
  rescue LoadError => e
82
- REQUIRE_ERRORS.find {|r| r =~ e.message }
83
- raise if dep.autorequire || $1 != required_file
74
+ raise if dep.autorequire || e.path != required_file
84
75
 
85
76
  if dep.autorequire.nil? && dep.name.include?("-")
86
77
  begin
87
78
  namespaced_file = dep.name.tr("-", "/")
88
79
  Kernel.require namespaced_file
89
80
  rescue LoadError => e
90
- REQUIRE_ERRORS.find {|r| r =~ e.message }
91
- raise if $1 != namespaced_file
81
+ raise if e.path != namespaced_file
92
82
  end
93
83
  end
94
84
  end
@@ -12,7 +12,6 @@ module Bundler
12
12
  allow_offline_install
13
13
  auto_clean_without_path
14
14
  auto_install
15
- auto_config_jobs
16
15
  cache_all
17
16
  cache_all_platforms
18
17
  default_install_uses_path
@@ -22,7 +21,6 @@ module Bundler
22
21
  disable_exec_load
23
22
  disable_local_branch_check
24
23
  disable_multisource
25
- disable_platform_warnings
26
24
  disable_shared_gems
27
25
  disable_version_check
28
26
  force_ruby_platform
@@ -44,7 +42,6 @@ module Bundler
44
42
  setup_makes_kernel_gem_public
45
43
  silence_deprecations
46
44
  silence_root_warning
47
- skip_default_git_sources
48
45
  specific_platform
49
46
  suppress_install_using_messages
50
47
  unlock_source_unlocks_spec
@@ -194,7 +194,7 @@ module Bundler
194
194
  return @md5_available if defined?(@md5_available)
195
195
  @md5_available = begin
196
196
  require "openssl"
197
- OpenSSL::Digest::MD5.digest("")
197
+ OpenSSL::Digest.digest("MD5", "")
198
198
  true
199
199
  rescue LoadError
200
200
  true