1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00
ruby--ruby/lib/bundler
Yusuke Endoh 75dca097b8 [bundler/bundler] Do require "rubygems" only when needed
This require causes circular require.

```
$ touch empty_file

$ RUBYGEMS_GEMDEPS=empty_file ./local/bin/ruby -w -e ''
/home/mame/work/ruby/local/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92: warning: /home/mame/work/ruby/local/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92: warning: loading in progress, circular require considered harmful - /home/mame/work/ruby/local/lib/ruby/2.7.0/rubygems.rb
	from <internal:gem_prelude>:1:in  `<internal:gem_prelude>'
	from <internal:gem_prelude>:1:in  `require'
	from /home/mame/work/ruby/local/lib/ruby/2.7.0/rubygems.rb:1417:in  `<top (required)>'
	from /home/mame/work/ruby/local/lib/ruby/2.7.0/rubygems.rb:1203:in  `use_gemdeps'
	from /home/mame/work/ruby/local/lib/ruby/2.7.0/rubygems/user_interaction.rb:47:in  `use_ui'
	from /home/mame/work/ruby/local/lib/ruby/2.7.0/rubygems.rb:1204:in  `block in use_gemdeps'
	from /home/mame/work/ruby/local/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in  `require'
	from /home/mame/work/ruby/local/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in  `require'
	from /home/mame/work/ruby/local/lib/ruby/2.7.0/bundler.rb:11:in  `<top (required)>'
	from /home/mame/work/ruby/local/lib/ruby/2.7.0/bundler.rb:11:in  `require_relative'
	from /home/mame/work/ruby/local/lib/ruby/2.7.0/bundler/rubygems_integration.rb:3:in  `<top (required)>'
	from /home/mame/work/ruby/local/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in  `require'
	from /home/mame/work/ruby/local/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in  `require'
```

https://github.com/bundler/bundler/commit/c7c5bcea92
2019-12-25 15:38:55 +09:00
..
cli
compact_index_client
fetcher
installer
plugin
resolver
settings
source
templates
ui
vendor
build_metadata.rb
bundler.gemspec
capistrano.rb
cli.rb
compact_index_client.rb
constants.rb
current_ruby.rb
definition.rb
dep_proxy.rb
dependency.rb
deployment.rb
deprecate.rb
dsl.rb
endpoint_specification.rb
env.rb
environment_preserver.rb
errors.rb
feature_flag.rb
fetcher.rb
friendly_errors.rb
gem_helper.rb
gem_helpers.rb
gem_remote_fetcher.rb
gem_tasks.rb
gem_version_promoter.rb
gemdeps.rb
graph.rb
index.rb
injector.rb
inline.rb
installer.rb
lazy_specification.rb
lockfile_generator.rb
lockfile_parser.rb
match_platform.rb
mirror.rb
plugin.rb
process_lock.rb
psyched_yaml.rb
remote_specification.rb
resolver.rb
retry.rb
ruby_dsl.rb
ruby_version.rb
rubygems_ext.rb
rubygems_gem_installer.rb
rubygems_integration.rb
runtime.rb
settings.rb
setup.rb
shared_helpers.rb
similarity_detector.rb
source.rb
source_list.rb
spec_set.rb
stub_specification.rb
ui.rb
uri_credentials_filter.rb
vendored_fileutils.rb
vendored_molinillo.rb
vendored_persistent.rb
vendored_thor.rb
vendored_uri.rb
version.rb
version_ranges.rb
vlad.rb
worker.rb
yaml_serializer.rb