rubygems-update 4.0.21 → 4.1.0.beta1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +590 -53
- data/CONTRIBUTING.md +66 -5
- data/MIT.txt +4 -3
- data/Manifest.txt +332 -375
- data/README.md +26 -6
- data/bundler.gemspec +63 -0
- data/doc/POLICIES.md +147 -0
- data/doc/UPGRADING.md +4 -4
- data/{bundler/lib → lib}/bundler/build_metadata.rb +2 -2
- data/{bundler/lib → lib}/bundler/checksum.rb +40 -25
- data/{bundler/lib → lib}/bundler/ci_detector.rb +1 -1
- data/{bundler/lib → lib}/bundler/cli/add.rb +3 -4
- data/{bundler/lib → lib}/bundler/cli/cache.rb +4 -0
- data/{bundler/lib → lib}/bundler/cli/clean.rb +5 -0
- data/{bundler/lib → lib}/bundler/cli/common.rb +37 -1
- data/{bundler/lib → lib}/bundler/cli/config.rb +4 -2
- data/{bundler/lib → lib}/bundler/cli/gem.rb +0 -17
- data/{bundler/lib → lib}/bundler/cli/install.rb +4 -5
- data/{bundler/lib → lib}/bundler/cli/lock.rb +1 -2
- data/{bundler/lib → lib}/bundler/cli/outdated.rb +8 -3
- data/{bundler/lib → lib}/bundler/cli/pristine.rb +2 -1
- data/{bundler/lib → lib}/bundler/cli/update.rb +21 -12
- data/{bundler/lib → lib}/bundler/cli.rb +14 -11
- data/{bundler/lib → lib}/bundler/definition.rb +61 -24
- data/{bundler/lib → lib}/bundler/dependency.rb +4 -0
- data/{bundler/lib → lib}/bundler/dsl.rb +77 -11
- data/{bundler/lib → lib}/bundler/endpoint_specification.rb +51 -14
- data/{bundler/lib → lib}/bundler/env.rb +7 -24
- data/{bundler/lib → lib}/bundler/errors.rb +34 -5
- data/{bundler/lib → lib}/bundler/fetcher/compact_index.rb +14 -5
- data/lib/bundler/fetcher/connection_pools.rb +150 -0
- data/{bundler/lib → lib}/bundler/fetcher/downloader.rb +31 -16
- data/{bundler/lib → lib}/bundler/fetcher.rb +8 -47
- data/{bundler/lib → lib}/bundler/injector.rb +3 -3
- data/{bundler/lib → lib}/bundler/inline.rb +44 -4
- data/{bundler/lib → lib}/bundler/installer/parallel_installer.rb +25 -30
- data/{bundler/lib → lib}/bundler/installer.rb +20 -6
- data/{bundler/lib → lib}/bundler/lazy_specification.rb +44 -17
- data/{bundler/lib → lib}/bundler/lockfile_generator.rb +24 -2
- data/{bundler/lib → lib}/bundler/lockfile_parser.rb +43 -5
- data/{bundler/lib → lib}/bundler/man/bundle-add.1 +7 -4
- data/{bundler/lib → lib}/bundler/man/bundle-add.1.ronn +8 -4
- data/{bundler/lib → lib}/bundler/man/bundle-binstubs.1 +1 -1
- data/{bundler/lib → lib}/bundler/man/bundle-cache.1 +2 -2
- data/{bundler/lib → lib}/bundler/man/bundle-cache.1.ronn +2 -2
- data/{bundler/lib → lib}/bundler/man/bundle-check.1 +1 -1
- data/{bundler/lib → lib}/bundler/man/bundle-clean.1 +1 -1
- data/{bundler/lib → lib}/bundler/man/bundle-config.1 +38 -6
- data/{bundler/lib → lib}/bundler/man/bundle-config.1.ronn +143 -10
- data/{bundler/lib → lib}/bundler/man/bundle-console.1 +1 -1
- data/{bundler/lib → lib}/bundler/man/bundle-doctor.1 +1 -1
- data/{bundler/lib → lib}/bundler/man/bundle-env.1 +1 -1
- data/{bundler/lib → lib}/bundler/man/bundle-exec.1 +1 -1
- data/{bundler/lib → lib}/bundler/man/bundle-fund.1 +1 -1
- data/{bundler/lib → lib}/bundler/man/bundle-gem.1 +1 -1
- data/{bundler/lib → lib}/bundler/man/bundle-help.1 +1 -1
- data/{bundler/lib → lib}/bundler/man/bundle-info.1 +1 -1
- data/{bundler/lib → lib}/bundler/man/bundle-init.1 +1 -1
- data/{bundler/lib → lib}/bundler/man/bundle-install.1 +2 -2
- data/{bundler/lib → lib}/bundler/man/bundle-install.1.ronn +4 -4
- data/{bundler/lib → lib}/bundler/man/bundle-issue.1 +1 -1
- data/{bundler/lib → lib}/bundler/man/bundle-licenses.1 +1 -1
- data/{bundler/lib → lib}/bundler/man/bundle-list.1 +1 -1
- data/{bundler/lib → lib}/bundler/man/bundle-lock.1 +3 -3
- data/{bundler/lib → lib}/bundler/man/bundle-lock.1.ronn +5 -5
- data/{bundler/lib → lib}/bundler/man/bundle-open.1 +1 -1
- data/{bundler/lib → lib}/bundler/man/bundle-outdated.1 +1 -1
- data/{bundler/lib → lib}/bundler/man/bundle-platform.1 +1 -1
- data/{bundler/lib → lib}/bundler/man/bundle-plugin.1 +1 -1
- data/{bundler/lib → lib}/bundler/man/bundle-pristine.1 +1 -1
- data/{bundler/lib → lib}/bundler/man/bundle-remove.1 +1 -1
- data/{bundler/lib → lib}/bundler/man/bundle-show.1 +1 -1
- data/{bundler/lib → lib}/bundler/man/bundle-update.1 +3 -3
- data/{bundler/lib → lib}/bundler/man/bundle-update.1.ronn +3 -5
- data/{bundler/lib → lib}/bundler/man/bundle-version.1 +1 -1
- data/{bundler/lib → lib}/bundler/man/bundle.1 +1 -1
- data/{bundler/lib → lib}/bundler/man/gemfile.5 +45 -1
- data/{bundler/lib → lib}/bundler/man/gemfile.5.ronn +53 -0
- data/lib/bundler/match_metadata.rb +50 -0
- data/{bundler/lib → lib}/bundler/match_platform.rb +25 -2
- data/lib/bundler/match_remote_metadata.rb +44 -0
- data/{bundler/lib → lib}/bundler/materialization.rb +2 -1
- data/lib/bundler/override.rb +69 -0
- data/{bundler/lib → lib}/bundler/plugin/dsl.rb +3 -5
- data/{bundler/lib → lib}/bundler/plugin/events.rb +55 -13
- data/{bundler/lib → lib}/bundler/plugin/index.rb +87 -11
- data/{bundler/lib → lib}/bundler/plugin/installer/path.rb +1 -1
- data/{bundler/lib → lib}/bundler/plugin/installer.rb +13 -5
- data/{bundler/lib → lib}/bundler/plugin.rb +58 -30
- data/{bundler/lib → lib}/bundler/remote_specification.rb +6 -3
- data/{bundler/lib → lib}/bundler/resolver/base.rb +2 -1
- data/{bundler/lib → lib}/bundler/resolver/incompatibility.rb +1 -1
- data/{bundler/lib → lib}/bundler/resolver.rb +73 -23
- data/{bundler/lib → lib}/bundler/ruby_version.rb +0 -2
- data/{bundler/lib → lib}/bundler/rubygems_ext.rb +71 -1
- data/{bundler/lib → lib}/bundler/rubygems_gem_installer.rb +41 -2
- data/{bundler/lib → lib}/bundler/rubygems_integration.rb +7 -2
- data/{bundler/lib → lib}/bundler/runtime.rb +69 -2
- data/{bundler/lib → lib}/bundler/self_manager.rb +9 -15
- data/{bundler/lib → lib}/bundler/settings.rb +373 -30
- data/{bundler/lib → lib}/bundler/shared_helpers.rb +2 -1
- data/{bundler/lib → lib}/bundler/source/git/git_proxy.rb +2 -10
- data/{bundler/lib → lib}/bundler/source/git.rb +15 -6
- data/{bundler/lib → lib}/bundler/source/path/installer.rb +1 -1
- data/{bundler/lib → lib}/bundler/source/rubygems/remote.rb +10 -5
- data/{bundler/lib → lib}/bundler/source/rubygems.rb +48 -12
- data/{bundler/lib → lib}/bundler/spec_set.rb +16 -4
- data/{bundler/lib → lib}/bundler/stub_specification.rb +2 -1
- data/{bundler/lib → lib}/bundler/templates/newgem/Gemfile.tt +4 -4
- data/{bundler/lib → lib}/bundler/templates/newgem/newgem.gemspec.tt +3 -3
- data/{bundler/lib → lib}/bundler/templates/newgem/spec/newgem_spec.rb.tt +1 -1
- data/{bundler/lib → lib}/bundler/templates/newgem/test/minitest/test_newgem.rb.tt +1 -1
- data/{bundler/lib → lib}/bundler/ui/shell.rb +0 -4
- data/{bundler/lib → lib}/bundler/ui/silent.rb +0 -4
- data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/actions/inject_into_file.rb +35 -2
- data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/base.rb +2 -1
- data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/shell/basic.rb +14 -6
- data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/shell/color.rb +2 -0
- data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/version.rb +1 -1
- data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor.rb +34 -1
- data/lib/bundler/vendored_pub_grub.rb +7 -0
- data/lib/bundler/vendored_securerandom.rb +15 -0
- data/lib/bundler/vendored_uri.rb +21 -0
- data/{bundler/lib → lib}/bundler/version.rb +1 -1
- data/{bundler/lib → lib}/bundler/worker.rb +3 -2
- data/{bundler/lib → lib}/bundler.rb +1 -1
- data/lib/rubygems/basic_specification.rb +15 -14
- data/lib/rubygems/bundler_settings.rb +137 -0
- data/lib/rubygems/bundler_version_finder.rb +13 -55
- data/lib/rubygems/ci_detector.rb +1 -1
- data/lib/rubygems/commands/build_command.rb +8 -1
- data/lib/rubygems/commands/cert_command.rb +9 -7
- data/lib/rubygems/commands/contents_command.rb +1 -1
- data/lib/rubygems/commands/dependency_command.rb +15 -3
- data/lib/rubygems/commands/environment_command.rb +1 -0
- data/lib/rubygems/commands/exec_command.rb +3 -0
- data/lib/rubygems/commands/fetch_command.rb +1 -1
- data/lib/rubygems/commands/help_command.rb +3 -1
- data/lib/rubygems/commands/install_command.rb +13 -3
- data/lib/rubygems/commands/lock_command.rb +2 -2
- data/lib/rubygems/commands/outdated_command.rb +77 -2
- data/lib/rubygems/commands/owner_command.rb +1 -1
- data/lib/rubygems/commands/push_command.rb +159 -21
- data/lib/rubygems/commands/setup_command.rb +20 -23
- data/lib/rubygems/commands/signin_command.rb +3 -1
- data/lib/rubygems/commands/signout_command.rb +26 -6
- data/lib/rubygems/commands/specification_command.rb +1 -1
- data/lib/rubygems/commands/uninstall_command.rb +1 -1
- data/lib/rubygems/commands/update_command.rb +84 -2
- data/lib/rubygems/commands/yank_command.rb +10 -7
- data/lib/rubygems/compact_index_client/cache.rb +122 -0
- data/lib/rubygems/compact_index_client/cache_file.rb +147 -0
- data/lib/rubygems/compact_index_client/http_fetcher.rb +88 -0
- data/lib/rubygems/compact_index_client/parser.rb +90 -0
- data/lib/rubygems/compact_index_client/updater.rb +113 -0
- data/lib/rubygems/compact_index_client.rb +111 -0
- data/lib/rubygems/config_file.rb +304 -22
- data/lib/rubygems/content_address.rb +194 -0
- data/lib/rubygems/cooldown.rb +173 -0
- data/lib/rubygems/cooldown_option.rb +27 -0
- data/lib/rubygems/cooldown_settings.rb +57 -0
- data/lib/rubygems/credential_store/native/linux.rb +97 -0
- data/lib/rubygems/credential_store/native/macos.rb +88 -0
- data/lib/rubygems/credential_store/native/windows.rb +130 -0
- data/lib/rubygems/credential_store.rb +332 -0
- data/lib/rubygems/defaults.rb +9 -0
- data/lib/rubygems/dependency_installer.rb +15 -0
- data/lib/rubygems/doctor.rb +23 -6
- data/lib/rubygems/exceptions.rb +11 -43
- data/lib/rubygems/ext/builder.rb +70 -5
- data/lib/rubygems/ext/cargo_builder.rb +0 -9
- data/lib/rubygems/ext/ext_conf_builder.rb +8 -15
- data/lib/rubygems/gemcutter_utilities.rb +44 -2
- data/lib/rubygems/install_update_options.rb +16 -0
- data/lib/rubygems/installer.rb +90 -11
- data/lib/rubygems/installer_uninstaller_utils.rb +24 -3
- data/lib/rubygems/name_tuple.rb +55 -18
- data/lib/rubygems/package/old.rb +1 -1
- data/lib/rubygems/package.rb +200 -47
- data/lib/rubygems/package_task.rb +2 -2
- data/lib/rubygems/platform.rb +2 -2
- data/lib/rubygems/query_utils.rb +84 -24
- data/lib/rubygems/remote_fetcher.rb +65 -17
- data/lib/rubygems/request/connection_pools.rb +3 -0
- data/lib/rubygems/request_set/gem_dependency_api.rb +1 -1
- data/lib/rubygems/request_set/lockfile.rb +0 -2
- data/lib/rubygems/request_set.rb +105 -17
- data/lib/rubygems/resolver/api_set.rb +14 -26
- data/lib/rubygems/resolver/api_specification.rb +56 -15
- data/lib/rubygems/resolver/incompatibility.rb +10 -0
- data/lib/rubygems/resolver/index_specification.rb +6 -4
- data/lib/rubygems/resolver/installer_set.rb +2 -2
- data/lib/rubygems/resolver/lock_specification.rb +5 -1
- data/lib/rubygems/resolver/spec_specification.rb +4 -0
- data/lib/rubygems/resolver/specification.rb +16 -1
- data/lib/rubygems/resolver/strategy.rb +44 -0
- data/lib/rubygems/resolver.rb +471 -145
- data/lib/rubygems/safe_marshal.rb +2 -1
- data/lib/rubygems/safe_yaml.rb +20 -3
- data/lib/rubygems/security/policy.rb +11 -3
- data/lib/rubygems/security/signer.rb +15 -7
- data/lib/rubygems/security.rb +111 -17
- data/lib/rubygems/source/local.rb +7 -2
- data/lib/rubygems/source.rb +270 -23
- data/lib/rubygems/spec_fetcher.rb +47 -12
- data/lib/rubygems/specification.rb +76 -32
- data/lib/rubygems/specification_policy.rb +33 -6
- data/lib/rubygems/specification_record.rb +41 -2
- data/lib/rubygems/stub_specification.rb +39 -16
- data/lib/rubygems/uninstaller.rb +2 -0
- data/lib/rubygems/util/atomic_file_writer.rb +109 -0
- data/lib/rubygems/vendor/net-http/lib/net/http/exceptions.rb +2 -1
- data/lib/rubygems/vendor/net-http/lib/net/http/generic_request.rb +5 -6
- data/lib/rubygems/vendor/net-http/lib/net/http/header.rb +8 -4
- data/lib/rubygems/vendor/net-http/lib/net/http/requests.rb +15 -1
- data/lib/rubygems/vendor/net-http/lib/net/http/response.rb +2 -1
- data/lib/rubygems/vendor/net-http/lib/net/http/responses.rb +68 -0
- data/lib/rubygems/vendor/net-http/lib/net/http.rb +60 -49
- data/lib/rubygems/vendor/optparse/lib/optparse.rb +23 -30
- data/{bundler/lib/bundler → lib/rubygems}/vendor/pub_grub/lib/pub_grub/assignment.rb +1 -1
- data/{bundler/lib/bundler → lib/rubygems}/vendor/pub_grub/lib/pub_grub/basic_package_source.rb +7 -7
- data/{bundler/lib/bundler → lib/rubygems}/vendor/pub_grub/lib/pub_grub/failure_writer.rb +1 -1
- data/{bundler/lib/bundler → lib/rubygems}/vendor/pub_grub/lib/pub_grub/incompatibility.rb +4 -4
- data/{bundler/lib/bundler → lib/rubygems}/vendor/pub_grub/lib/pub_grub/package.rb +1 -1
- data/{bundler/lib/bundler → lib/rubygems}/vendor/pub_grub/lib/pub_grub/partial_solution.rb +1 -1
- data/{bundler/lib/bundler → lib/rubygems}/vendor/pub_grub/lib/pub_grub/rubygems.rb +3 -3
- data/{bundler/lib/bundler → lib/rubygems}/vendor/pub_grub/lib/pub_grub/solve_failure.rb +1 -1
- data/{bundler/lib/bundler → lib/rubygems}/vendor/pub_grub/lib/pub_grub/static_package_source.rb +3 -3
- data/{bundler/lib/bundler → lib/rubygems}/vendor/pub_grub/lib/pub_grub/strategy.rb +2 -2
- data/{bundler/lib/bundler → lib/rubygems}/vendor/pub_grub/lib/pub_grub/term.rb +1 -1
- data/{bundler/lib/bundler → lib/rubygems}/vendor/pub_grub/lib/pub_grub/version.rb +1 -1
- data/{bundler/lib/bundler → lib/rubygems}/vendor/pub_grub/lib/pub_grub/version_constraint.rb +3 -3
- data/{bundler/lib/bundler → lib/rubygems}/vendor/pub_grub/lib/pub_grub/version_range.rb +1 -1
- data/{bundler/lib/bundler → lib/rubygems}/vendor/pub_grub/lib/pub_grub/version_solver.rb +2 -2
- data/{bundler/lib/bundler → lib/rubygems}/vendor/pub_grub/lib/pub_grub/version_union.rb +1 -1
- data/lib/rubygems/vendor/pub_grub/lib/pub_grub.rb +57 -0
- data/lib/rubygems/vendor/resolv/lib/resolv.rb +3508 -0
- data/lib/rubygems/vendor/securerandom/lib/securerandom.rb +4 -0
- data/lib/rubygems/vendor/timeout/lib/timeout.rb +190 -77
- data/lib/rubygems/vendor/uri/lib/uri.rb +4 -0
- data/{bundler/lib/bundler → lib/rubygems}/vendored_pub_grub.rb +0 -1
- data/lib/rubygems/version.rb +129 -111
- data/lib/rubygems/version_option.rb +14 -0
- data/lib/rubygems/yaml_serializer.rb +853 -71
- data/lib/rubygems.rb +45 -11
- data/rubygems-update.gemspec +3 -4
- data/setup.rb +1 -0
- metadata +365 -410
- data/bundler/CHANGELOG.md +0 -5784
- data/bundler/LICENSE.md +0 -22
- data/bundler/README.md +0 -58
- data/bundler/bundler.gemspec +0 -46
- data/bundler/lib/bundler/compact_index_client/cache.rb +0 -107
- data/bundler/lib/bundler/compact_index_client/cache_file.rb +0 -148
- data/bundler/lib/bundler/compact_index_client/parser.rb +0 -87
- data/bundler/lib/bundler/compact_index_client/updater.rb +0 -105
- data/bundler/lib/bundler/compact_index_client.rb +0 -92
- data/bundler/lib/bundler/match_metadata.rb +0 -30
- data/bundler/lib/bundler/match_remote_metadata.rb +0 -29
- data/bundler/lib/bundler/vendor/connection_pool/LICENSE +0 -20
- data/bundler/lib/bundler/vendor/connection_pool/lib/connection_pool/timed_stack.rb +0 -227
- data/bundler/lib/bundler/vendor/connection_pool/lib/connection_pool/version.rb +0 -3
- data/bundler/lib/bundler/vendor/connection_pool/lib/connection_pool/wrapper.rb +0 -56
- data/bundler/lib/bundler/vendor/connection_pool/lib/connection_pool.rb +0 -230
- data/bundler/lib/bundler/vendor/net-http-persistent/README.rdoc +0 -82
- data/bundler/lib/bundler/vendor/net-http-persistent/lib/net/http/persistent/connection.rb +0 -41
- data/bundler/lib/bundler/vendor/net-http-persistent/lib/net/http/persistent/pool.rb +0 -65
- data/bundler/lib/bundler/vendor/net-http-persistent/lib/net/http/persistent/timed_stack_multi.rb +0 -80
- data/bundler/lib/bundler/vendor/net-http-persistent/lib/net/http/persistent.rb +0 -1153
- data/bundler/lib/bundler/vendor/pub_grub/lib/pub_grub.rb +0 -31
- data/bundler/lib/bundler/vendor/securerandom/lib/securerandom.rb +0 -102
- data/bundler/lib/bundler/vendor/uri/COPYING +0 -56
- data/bundler/lib/bundler/vendor/uri/lib/uri/common.rb +0 -922
- data/bundler/lib/bundler/vendor/uri/lib/uri/file.rb +0 -100
- data/bundler/lib/bundler/vendor/uri/lib/uri/ftp.rb +0 -267
- data/bundler/lib/bundler/vendor/uri/lib/uri/generic.rb +0 -1592
- data/bundler/lib/bundler/vendor/uri/lib/uri/http.rb +0 -137
- data/bundler/lib/bundler/vendor/uri/lib/uri/https.rb +0 -23
- data/bundler/lib/bundler/vendor/uri/lib/uri/ldap.rb +0 -261
- data/bundler/lib/bundler/vendor/uri/lib/uri/ldaps.rb +0 -22
- data/bundler/lib/bundler/vendor/uri/lib/uri/mailto.rb +0 -293
- data/bundler/lib/bundler/vendor/uri/lib/uri/rfc2396_parser.rb +0 -547
- data/bundler/lib/bundler/vendor/uri/lib/uri/rfc3986_parser.rb +0 -206
- data/bundler/lib/bundler/vendor/uri/lib/uri/version.rb +0 -6
- data/bundler/lib/bundler/vendor/uri/lib/uri/ws.rb +0 -83
- data/bundler/lib/bundler/vendor/uri/lib/uri/wss.rb +0 -23
- data/bundler/lib/bundler/vendor/uri/lib/uri.rb +0 -104
- data/bundler/lib/bundler/vendored_persistent.rb +0 -11
- data/bundler/lib/bundler/vendored_securerandom.rb +0 -12
- data/bundler/lib/bundler/vendored_uri.rb +0 -21
- data/bundler/lib/bundler/yaml_serializer.rb +0 -98
- data/doc/rubygems/CONTRIBUTING.md +0 -231
- data/doc/rubygems/POLICIES.md +0 -60
- data/lib/rubygems/request_set/lockfile/parser.rb +0 -344
- data/lib/rubygems/request_set/lockfile/tokenizer.rb +0 -122
- data/lib/rubygems/resolver/conflict.rb +0 -146
- data/lib/rubygems/resolver/stats.rb +0 -46
- data/lib/rubygems/util/list.rb +0 -40
- data/lib/rubygems/vendor/molinillo/LICENSE +0 -9
- data/lib/rubygems/vendor/molinillo/lib/molinillo/delegates/resolution_state.rb +0 -57
- data/lib/rubygems/vendor/molinillo/lib/molinillo/delegates/specification_provider.rb +0 -88
- data/lib/rubygems/vendor/molinillo/lib/molinillo/dependency_graph/action.rb +0 -36
- data/lib/rubygems/vendor/molinillo/lib/molinillo/dependency_graph/add_edge_no_circular.rb +0 -66
- data/lib/rubygems/vendor/molinillo/lib/molinillo/dependency_graph/add_vertex.rb +0 -62
- data/lib/rubygems/vendor/molinillo/lib/molinillo/dependency_graph/delete_edge.rb +0 -63
- data/lib/rubygems/vendor/molinillo/lib/molinillo/dependency_graph/detach_vertex_named.rb +0 -61
- data/lib/rubygems/vendor/molinillo/lib/molinillo/dependency_graph/log.rb +0 -126
- data/lib/rubygems/vendor/molinillo/lib/molinillo/dependency_graph/set_payload.rb +0 -46
- data/lib/rubygems/vendor/molinillo/lib/molinillo/dependency_graph/tag.rb +0 -36
- data/lib/rubygems/vendor/molinillo/lib/molinillo/dependency_graph/vertex.rb +0 -164
- data/lib/rubygems/vendor/molinillo/lib/molinillo/dependency_graph.rb +0 -255
- data/lib/rubygems/vendor/molinillo/lib/molinillo/errors.rb +0 -149
- data/lib/rubygems/vendor/molinillo/lib/molinillo/gem_metadata.rb +0 -6
- data/lib/rubygems/vendor/molinillo/lib/molinillo/modules/specification_provider.rb +0 -112
- data/lib/rubygems/vendor/molinillo/lib/molinillo/modules/ui.rb +0 -67
- data/lib/rubygems/vendor/molinillo/lib/molinillo/resolution.rb +0 -839
- data/lib/rubygems/vendor/molinillo/lib/molinillo/resolver.rb +0 -46
- data/lib/rubygems/vendor/molinillo/lib/molinillo/state.rb +0 -58
- data/lib/rubygems/vendor/molinillo/lib/molinillo.rb +0 -11
- data/lib/rubygems/vendored_molinillo.rb +0 -3
- /data/{bundler/exe → exe}/bundle +0 -0
- /data/{bundler/exe → exe}/bundler +0 -0
- /data/{bundler/lib → lib}/bundler/.document +0 -0
- /data/{bundler/lib → lib}/bundler/capistrano.rb +0 -0
- /data/{bundler/lib → lib}/bundler/cli/binstubs.rb +0 -0
- /data/{bundler/lib → lib}/bundler/cli/check.rb +0 -0
- /data/{bundler/lib → lib}/bundler/cli/console.rb +0 -0
- /data/{bundler/lib → lib}/bundler/cli/doctor/diagnose.rb +0 -0
- /data/{bundler/lib → lib}/bundler/cli/doctor/ssl.rb +0 -0
- /data/{bundler/lib → lib}/bundler/cli/doctor.rb +0 -0
- /data/{bundler/lib → lib}/bundler/cli/exec.rb +0 -0
- /data/{bundler/lib → lib}/bundler/cli/fund.rb +0 -0
- /data/{bundler/lib → lib}/bundler/cli/info.rb +0 -0
- /data/{bundler/lib → lib}/bundler/cli/init.rb +0 -0
- /data/{bundler/lib → lib}/bundler/cli/issue.rb +0 -0
- /data/{bundler/lib → lib}/bundler/cli/list.rb +0 -0
- /data/{bundler/lib → lib}/bundler/cli/open.rb +0 -0
- /data/{bundler/lib → lib}/bundler/cli/platform.rb +0 -0
- /data/{bundler/lib → lib}/bundler/cli/plugin.rb +0 -0
- /data/{bundler/lib → lib}/bundler/cli/remove.rb +0 -0
- /data/{bundler/lib → lib}/bundler/cli/show.rb +0 -0
- /data/{bundler/lib → lib}/bundler/constants.rb +0 -0
- /data/{bundler/lib → lib}/bundler/current_ruby.rb +0 -0
- /data/{bundler/lib → lib}/bundler/deployment.rb +0 -0
- /data/{bundler/lib → lib}/bundler/deprecate.rb +0 -0
- /data/{bundler/lib → lib}/bundler/digest.rb +0 -0
- /data/{bundler/lib → lib}/bundler/environment_preserver.rb +0 -0
- /data/{bundler/lib → lib}/bundler/feature_flag.rb +0 -0
- /data/{bundler/lib → lib}/bundler/fetcher/base.rb +0 -0
- /data/{bundler/lib → lib}/bundler/fetcher/dependency.rb +0 -0
- /data/{bundler/lib → lib}/bundler/fetcher/gem_remote_fetcher.rb +0 -0
- /data/{bundler/lib → lib}/bundler/fetcher/index.rb +0 -0
- /data/{bundler/lib → lib}/bundler/force_platform.rb +0 -0
- /data/{bundler/lib → lib}/bundler/friendly_errors.rb +0 -0
- /data/{bundler/lib → lib}/bundler/gem_helper.rb +0 -0
- /data/{bundler/lib → lib}/bundler/gem_tasks.rb +0 -0
- /data/{bundler/lib → lib}/bundler/gem_version_promoter.rb +0 -0
- /data/{bundler/lib → lib}/bundler/index.rb +0 -0
- /data/{bundler/lib → lib}/bundler/installer/gem_installer.rb +0 -0
- /data/{bundler/lib → lib}/bundler/installer/standalone.rb +0 -0
- /data/{bundler/lib → lib}/bundler/man/.document +0 -0
- /data/{bundler/lib → lib}/bundler/man/bundle-binstubs.1.ronn +0 -0
- /data/{bundler/lib → lib}/bundler/man/bundle-check.1.ronn +0 -0
- /data/{bundler/lib → lib}/bundler/man/bundle-clean.1.ronn +0 -0
- /data/{bundler/lib → lib}/bundler/man/bundle-console.1.ronn +0 -0
- /data/{bundler/lib → lib}/bundler/man/bundle-doctor.1.ronn +0 -0
- /data/{bundler/lib → lib}/bundler/man/bundle-env.1.ronn +0 -0
- /data/{bundler/lib → lib}/bundler/man/bundle-exec.1.ronn +0 -0
- /data/{bundler/lib → lib}/bundler/man/bundle-fund.1.ronn +0 -0
- /data/{bundler/lib → lib}/bundler/man/bundle-gem.1.ronn +0 -0
- /data/{bundler/lib → lib}/bundler/man/bundle-help.1.ronn +0 -0
- /data/{bundler/lib → lib}/bundler/man/bundle-info.1.ronn +0 -0
- /data/{bundler/lib → lib}/bundler/man/bundle-init.1.ronn +0 -0
- /data/{bundler/lib → lib}/bundler/man/bundle-issue.1.ronn +0 -0
- /data/{bundler/lib → lib}/bundler/man/bundle-licenses.1.ronn +0 -0
- /data/{bundler/lib → lib}/bundler/man/bundle-list.1.ronn +0 -0
- /data/{bundler/lib → lib}/bundler/man/bundle-open.1.ronn +0 -0
- /data/{bundler/lib → lib}/bundler/man/bundle-outdated.1.ronn +0 -0
- /data/{bundler/lib → lib}/bundler/man/bundle-platform.1.ronn +0 -0
- /data/{bundler/lib → lib}/bundler/man/bundle-plugin.1.ronn +0 -0
- /data/{bundler/lib → lib}/bundler/man/bundle-pristine.1.ronn +0 -0
- /data/{bundler/lib → lib}/bundler/man/bundle-remove.1.ronn +0 -0
- /data/{bundler/lib → lib}/bundler/man/bundle-show.1.ronn +0 -0
- /data/{bundler/lib → lib}/bundler/man/bundle-version.1.ronn +0 -0
- /data/{bundler/lib → lib}/bundler/man/bundle.1.ronn +0 -0
- /data/{bundler/lib → lib}/bundler/man/index.txt +0 -0
- /data/{bundler/lib → lib}/bundler/mirror.rb +0 -0
- /data/{bundler/lib → lib}/bundler/plugin/api/source.rb +0 -0
- /data/{bundler/lib → lib}/bundler/plugin/api.rb +0 -0
- /data/{bundler/lib → lib}/bundler/plugin/installer/git.rb +0 -0
- /data/{bundler/lib → lib}/bundler/plugin/installer/rubygems.rb +0 -0
- /data/{bundler/lib → lib}/bundler/plugin/source_list.rb +0 -0
- /data/{bundler/lib → lib}/bundler/plugin/unloaded_source.rb +0 -0
- /data/{bundler/lib → lib}/bundler/process_lock.rb +0 -0
- /data/{bundler/lib → lib}/bundler/resolver/candidate.rb +0 -0
- /data/{bundler/lib → lib}/bundler/resolver/package.rb +0 -0
- /data/{bundler/lib → lib}/bundler/resolver/root.rb +0 -0
- /data/{bundler/lib → lib}/bundler/resolver/spec_group.rb +0 -0
- /data/{bundler/lib → lib}/bundler/resolver/strategy.rb +0 -0
- /data/{bundler/lib → lib}/bundler/retry.rb +0 -0
- /data/{bundler/lib → lib}/bundler/ruby_dsl.rb +0 -0
- /data/{bundler/lib → lib}/bundler/safe_marshal.rb +0 -0
- /data/{bundler/lib → lib}/bundler/settings/validator.rb +0 -0
- /data/{bundler/lib → lib}/bundler/setup.rb +0 -0
- /data/{bundler/lib → lib}/bundler/source/gemspec.rb +0 -0
- /data/{bundler/lib → lib}/bundler/source/metadata.rb +0 -0
- /data/{bundler/lib → lib}/bundler/source/path.rb +0 -0
- /data/{bundler/lib → lib}/bundler/source/rubygems_aggregate.rb +0 -0
- /data/{bundler/lib → lib}/bundler/source.rb +0 -0
- /data/{bundler/lib → lib}/bundler/source_list.rb +0 -0
- /data/{bundler/lib → lib}/bundler/source_map.rb +0 -0
- /data/{bundler/lib → lib}/bundler/templates/.document +0 -0
- /data/{bundler/lib → lib}/bundler/templates/Executable +0 -0
- /data/{bundler/lib → lib}/bundler/templates/Executable.standalone +0 -0
- /data/{bundler/lib → lib}/bundler/templates/Gemfile +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/CHANGELOG.md.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/CODE_OF_CONDUCT.md.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/Cargo.toml.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/LICENSE.txt.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/README.md.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/Rakefile.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/bin/console.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/bin/setup.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/circleci/config.yml.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/exe/newgem.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/ext/newgem/Cargo.toml.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/ext/newgem/build.rs.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/ext/newgem/extconf-c.rb.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/ext/newgem/extconf-go.rb.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/ext/newgem/extconf-rust.rb.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/ext/newgem/go.mod.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/ext/newgem/newgem-go.c.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/ext/newgem/newgem.c.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/ext/newgem/newgem.go.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/ext/newgem/newgem.h.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/ext/newgem/src/lib.rs.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/github/workflows/build-gems.yml.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/github/workflows/main.yml.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/gitignore.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/gitlab-ci.yml.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/lib/newgem/version.rb.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/lib/newgem.rb.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/rspec.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/rubocop.yml.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/sig/newgem.rbs.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/spec/spec_helper.rb.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/standard.yml.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/test/minitest/test_helper.rb.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/test/test-unit/newgem_test.rb.tt +0 -0
- /data/{bundler/lib → lib}/bundler/templates/newgem/test/test-unit/test_helper.rb.tt +0 -0
- /data/{bundler/lib → lib}/bundler/ui/rg_proxy.rb +0 -0
- /data/{bundler/lib → lib}/bundler/ui.rb +0 -0
- /data/{bundler/lib → lib}/bundler/uri_credentials_filter.rb +0 -0
- /data/{bundler/lib → lib}/bundler/uri_normalizer.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/.document +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/fileutils/COPYING +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/fileutils/lib/fileutils.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/LICENSE.md +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/actions/create_file.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/actions/create_link.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/actions/directory.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/actions/empty_directory.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/actions/file_manipulation.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/actions.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/command.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/core_ext/hash_with_indifferent_access.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/error.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/group.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/invocation.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/line_editor/basic.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/line_editor/readline.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/line_editor.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/nested_context.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/parser/argument.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/parser/arguments.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/parser/option.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/parser/options.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/parser.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/rake_compat.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/runner.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/shell/column_printer.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/shell/html.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/shell/table_printer.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/shell/terminal.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/shell/wrapped_printer.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/shell.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendor/thor/lib/thor/util.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendored_fileutils.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendored_net_http.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendored_thor.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendored_timeout.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vendored_tsort.rb +0 -0
- /data/{bundler/lib → lib}/bundler/vlad.rb +0 -0
- /data/{bundler/lib/bundler → lib/rubygems}/vendor/pub_grub/LICENSE.txt +0 -0
- /data/{bundler/lib/bundler/vendor/securerandom → lib/rubygems/vendor/resolv}/COPYING +0 -0
data/README.md
CHANGED
|
@@ -30,6 +30,23 @@ response = Faraday.get('https://rubygems.org')
|
|
|
30
30
|
|
|
31
31
|
For more information about how to use RubyGems, see our RubyGems basics guide at [guides.rubygems.org](https://guides.rubygems.org/rubygems-basics/)
|
|
32
32
|
|
|
33
|
+
## Bundler
|
|
34
|
+
|
|
35
|
+
Bundler makes sure Ruby applications run the same code on every machine. It is developed in this repository and ships with Ruby.
|
|
36
|
+
|
|
37
|
+
It does this by managing the gems that the application depends on. Given a list of gems, it can automatically download and install those gems, as well as any other gems needed by the gems that are listed. Before installing gems, it checks the versions of every gem to make sure that they are compatible, and can all be loaded at the same time. After the gems have been installed, Bundler can help you update some or all of them when new versions become available. Finally, it records the exact versions that have been installed, so that others can install the exact same gems.
|
|
38
|
+
|
|
39
|
+
For example, these commands will allow you to use Bundler to manage the `rspec` gem for your application:
|
|
40
|
+
|
|
41
|
+
```bash
|
|
42
|
+
bundle init
|
|
43
|
+
bundle add rspec
|
|
44
|
+
bundle install
|
|
45
|
+
bundle exec rspec
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
For more information about how to use Bundler, see the guides at [guides.rubygems.org](https://guides.rubygems.org/)
|
|
49
|
+
|
|
33
50
|
## Requirements
|
|
34
51
|
|
|
35
52
|
* RubyGems supports Ruby 3.0 or later.
|
|
@@ -69,9 +86,7 @@ See [UPGRADING](doc/UPGRADING.md) for more details and alternative instructions.
|
|
|
69
86
|
|
|
70
87
|
## Release policy
|
|
71
88
|
|
|
72
|
-
RubyGems and Bundler
|
|
73
|
-
major version number. It is planned that also their major version numbers will
|
|
74
|
-
be sync'ed in the future.
|
|
89
|
+
RubyGems and Bundler share a version number and are released together.
|
|
75
90
|
|
|
76
91
|
The release policy is somewhat similar to the release policy of Ruby itself:
|
|
77
92
|
|
|
@@ -102,15 +117,20 @@ for letting the RubyGems team know about bugs or problems you're having is
|
|
|
102
117
|
|
|
103
118
|
### Bundler Compatibility
|
|
104
119
|
|
|
105
|
-
See https://
|
|
120
|
+
See https://guides.rubygems.org/bundler-compatibility/ for known issues.
|
|
106
121
|
|
|
107
122
|
### Supporting
|
|
108
123
|
|
|
109
|
-
RubyGems is
|
|
124
|
+
RubyGems is a community project. Please consider sponsoring [individual contributors for their great OSS
|
|
125
|
+
work](https://github.com/ruby/rubygems/graphs/contributors).
|
|
126
|
+
|
|
127
|
+
In addition, Ruby Central administers grant-funded work for improvements to `ruby/rubygems`, as well as running
|
|
128
|
+
RubyGems.org (the service). You can support Ruby Central by attending or [sponsoring](mailto:sponsors@rubycentral.org)
|
|
129
|
+
a [RubyConf](https://rubyconf.org/), or by [joining as a supporting member](https://rubycentral.org/#/portal/signup).
|
|
110
130
|
|
|
111
131
|
### Contributing
|
|
112
132
|
|
|
113
|
-
If you'd like to contribute to RubyGems, that's awesome, and we <3 you. Check out our [guide to contributing](
|
|
133
|
+
If you'd like to contribute to RubyGems, that's awesome, and we <3 you. Check out our [guide to contributing](CONTRIBUTING.md) for more information.
|
|
114
134
|
|
|
115
135
|
### Code of Conduct
|
|
116
136
|
|
data/bundler.gemspec
ADDED
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
begin
|
|
4
|
+
require_relative "lib/bundler/version"
|
|
5
|
+
rescue LoadError
|
|
6
|
+
# for Ruby core repository
|
|
7
|
+
require_relative "version"
|
|
8
|
+
end
|
|
9
|
+
|
|
10
|
+
Gem::Specification.new do |s|
|
|
11
|
+
s.name = "bundler"
|
|
12
|
+
s.version = Bundler::VERSION
|
|
13
|
+
s.license = "MIT"
|
|
14
|
+
s.authors = [
|
|
15
|
+
"Yehuda Katz", "Carl Lerche", "André Arko", "Terence Lee", "Tim Moore",
|
|
16
|
+
"Jessica Lynn Suttles", "Hiroshi SHIBATA", "André Medeiros", "Samuel Giddins", "David Rodríguez",
|
|
17
|
+
"James Wen", "Chris Morris", "Colby Swandale", "Grey Baker", "Stephanie Morillo"
|
|
18
|
+
]
|
|
19
|
+
s.email = [
|
|
20
|
+
"wycats@gmail.com", "me@carllerche.com", "andre@arko.net", "hone02@gmail.com", "tmoore@incrementalism.net",
|
|
21
|
+
"jlsuttles@gmail.com", "hsbt@ruby-lang.org", "me@andremedeiros.info", "segiddins@segiddins.me", "deivid.rodriguez@riseup.net",
|
|
22
|
+
"jrw2175@columbia.edu", "chrismo@clabs.org", "colby@rubygems.org", "greysteil@gmail.com", ""
|
|
23
|
+
]
|
|
24
|
+
s.homepage = "https://bundler.io"
|
|
25
|
+
s.summary = "The best way to manage your application's dependencies"
|
|
26
|
+
s.description = "Bundler manages an application's dependencies through its entire life, across many machines, systematically and repeatably"
|
|
27
|
+
|
|
28
|
+
s.metadata = {
|
|
29
|
+
"bug_tracker_uri" => "https://github.com/ruby/rubygems/issues?q=is%3Aopen+is%3Aissue+label%3ABundler",
|
|
30
|
+
"changelog_uri" => "https://github.com/ruby/rubygems/blob/master/CHANGELOG.md",
|
|
31
|
+
"homepage_uri" => "https://bundler.io/",
|
|
32
|
+
"source_code_uri" => "https://github.com/ruby/rubygems",
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
s.required_ruby_version = ">= 3.2.0"
|
|
36
|
+
|
|
37
|
+
# It should match the RubyGems version shipped with `required_ruby_version` above
|
|
38
|
+
s.required_rubygems_version = ">= 3.4.1"
|
|
39
|
+
|
|
40
|
+
s.files = Dir.glob("lib/bundler{.rb,/**/*}", File::FNM_DOTMATCH).reject {|f| File.directory?(f) }
|
|
41
|
+
|
|
42
|
+
# Bundler reuses RubyGems' vendored URI, SecureRandom and PubGrub, its
|
|
43
|
+
# pure-Ruby YAML serializer, its shared cooldown setting rules, its compact
|
|
44
|
+
# index client and its credential store. Ship a copy under lib/rubygems so
|
|
45
|
+
# Bundler stays self-contained on RubyGems versions that predate them.
|
|
46
|
+
s.files += Dir.glob("lib/rubygems/vendor/uri/**/*", File::FNM_DOTMATCH).reject {|f| File.directory?(f) }
|
|
47
|
+
s.files += Dir.glob("lib/rubygems/vendor/securerandom/**/*", File::FNM_DOTMATCH).reject {|f| File.directory?(f) }
|
|
48
|
+
s.files += Dir.glob("lib/rubygems/vendor/pub_grub/**/*", File::FNM_DOTMATCH).reject {|f| File.directory?(f) }
|
|
49
|
+
s.files += Dir.glob("lib/rubygems/yaml_serializer.rb")
|
|
50
|
+
s.files += Dir.glob("lib/rubygems/cooldown_settings.rb")
|
|
51
|
+
s.files += Dir.glob("lib/rubygems/compact_index_client{.rb,/**/*}", File::FNM_DOTMATCH).reject {|f| File.directory?(f) }
|
|
52
|
+
s.files += Dir.glob("lib/rubygems/credential_store{.rb,/**/*}", File::FNM_DOTMATCH).reject {|f| File.directory?(f) }
|
|
53
|
+
|
|
54
|
+
# include the gemspec itself because warbler breaks w/o it
|
|
55
|
+
s.files += %w[bundler.gemspec]
|
|
56
|
+
|
|
57
|
+
# These live next to the gemspec when Bundler ships as a gem, but not when
|
|
58
|
+
# it is synced into Ruby core, where the gemspec moves under lib/bundler.
|
|
59
|
+
s.files += %w[MIT.txt].select {|f| File.file?(f) }
|
|
60
|
+
s.bindir = "exe"
|
|
61
|
+
s.executables = %w[bundle bundler]
|
|
62
|
+
s.require_paths = ["lib"]
|
|
63
|
+
end
|
data/doc/POLICIES.md
ADDED
|
@@ -0,0 +1,147 @@
|
|
|
1
|
+
# ruby/rubygems Policies
|
|
2
|
+
|
|
3
|
+
This document is an attempt to record the policies and processes that are used to govern this project--it's not fixed or permanent, and will likely evolve as events warrant.
|
|
4
|
+
|
|
5
|
+
## Our Goals
|
|
6
|
+
|
|
7
|
+
0. Treat everyone like a valuable human being, worthy of respect and empathy. No exceptions.
|
|
8
|
+
1. Strive to empower users, the Ruby developers who use RubyGems and Bundler. For example, there is no such thing as user error, only insufficient UX design.
|
|
9
|
+
2. Strive to empower contributors, as long as it does not harm users. For example, potential contributors should be able to set up a complete development and testing environment with a single command.
|
|
10
|
+
3. Strive to empower maintainers, as long as it does not harm contributors or users. For example, automating issue triage to reduce repetitive work for maintainers, as long as users with problems are not worse off.
|
|
11
|
+
|
|
12
|
+
These policies are intended to be examples of how to apply these goals, and we realize that we can't possibly cover every edge case or loophole. In any case where policies turn out to conflict with these goals, the goals should win.
|
|
13
|
+
|
|
14
|
+
## Issue guidelines
|
|
15
|
+
|
|
16
|
+
Anyone is welcome to open an issue, or comment on an issue. Issue comments without useful content (like “me too”) may be removed.
|
|
17
|
+
|
|
18
|
+
Opening an issue to ask for help may eventually get you help, but chances are help will arrive faster if you post on [Stack Overflow](https://stackoverflow.com)
|
|
19
|
+
|
|
20
|
+
Issues will be handled as soon as possible, which may take some time. Including a script that can be used to reproduce your issue is a great way to help maintainers help you. If you can, writing a failing test for your issue is even more helpful.
|
|
21
|
+
|
|
22
|
+
## Contribution and pull request guidelines
|
|
23
|
+
|
|
24
|
+
Contributions to RubyGems are made via GitHub pull requests, which must be
|
|
25
|
+
approved by a project committer other than the author. To approve a PR, a
|
|
26
|
+
maintainer can use GitHub's PR review feature. After that, if the original author
|
|
27
|
+
is happy to merge the PR, they can press the merge button.
|
|
28
|
+
|
|
29
|
+
Anyone is welcome to [contribute](../CONTRIBUTING.md). Contributed code will be released under the same license as the existing codebase.
|
|
30
|
+
|
|
31
|
+
Pull requests must have passing tests to be merged. Code changes must also include tests for the new behavior. Squashing commits is not required.
|
|
32
|
+
|
|
33
|
+
Every pull request should explain:
|
|
34
|
+
|
|
35
|
+
1. The problem being solved
|
|
36
|
+
2. Why that problem is happening
|
|
37
|
+
3. What changes to fix that problem are included in the PR, and
|
|
38
|
+
4. Why that implementation was chosen out of the possible options.
|
|
39
|
+
|
|
40
|
+
## Long-Term Support
|
|
41
|
+
|
|
42
|
+
### Ruby Version Support
|
|
43
|
+
|
|
44
|
+
Both RubyGems and Bundler support Ruby versions for as long as the Ruby team supports them, as [listed here](https://www.ruby-lang.org/en/downloads/branches/). When a Ruby version reaches end-of-life, the following minor release of RubyGems/Bundler will drop backwards compatibility with that Ruby version.
|
|
45
|
+
|
|
46
|
+
We also support the latest stable versions of JRuby and TruffleRuby, and constantly evaluate changes in Ruby implementation usage to potentially support more implementations.
|
|
47
|
+
|
|
48
|
+
### Version Support and Releases
|
|
49
|
+
|
|
50
|
+
The team ships features and bugfixes for the latest minor version. We may exceptionally backport security fixes to older series shipped with Rubies that are officially supported.
|
|
51
|
+
|
|
52
|
+
Security releases will be made for RubyGems and Bundler versions that were included in a currently-supported Ruby release. For example, if a version was shipped with a Ruby release, it will receive security fixes until that Ruby version reaches end-of-life.
|
|
53
|
+
|
|
54
|
+
We generally release bugfixes from the main branch and may mix bug fixes and new features in the same release. We do not guarantee bugfix releases for previous minor or major versions.
|
|
55
|
+
|
|
56
|
+
These policies are not a guarantee that any particular fix will be backported. Instead, this is a way for us to set an upper limit on the versions of Ruby, RubyGems, and Bundler that we have to consider while making changes. Without the limit, the number of versions grows exponentially over time and quickly becomes overwhelming, which leads to maintainer burnout. We want to avoid that.
|
|
57
|
+
|
|
58
|
+
### Backwards Compatibility
|
|
59
|
+
|
|
60
|
+
We strive for backwards compatibility. Infrastructure should be as unsurprising as possible, so if something worked in version 1.x, it should continue to work in 1.y and 1.z. Changes in major versions (e.g., 1.x to 2.x) may not maintain full backwards compatibility. We may not always get it right, and there may be extenuating circumstances that force us into choosing between different kinds of breakage, but compatibility is very important to us.
|
|
61
|
+
|
|
62
|
+
In general, this is what we consider as "public API":
|
|
63
|
+
|
|
64
|
+
* The `gem` and `bundle` CLIs. Flags and commands will never be removed without
|
|
65
|
+
deprecation, but we may change the specific output of certain commands without
|
|
66
|
+
notice, unless a `--parseable` or equivalent flag is given. Don't rely on
|
|
67
|
+
empty error output when checking success, since progress
|
|
68
|
+
may be logged to stderr. Instead, check the exit status of the command.
|
|
69
|
+
|
|
70
|
+
* The documented Gemfile DSL (both methods and their options).
|
|
71
|
+
|
|
72
|
+
* The lockfile format. We may introduce slight changes in new lockfiles, but
|
|
73
|
+
we'll keep being able to read what we previously generated and we'll keep it
|
|
74
|
+
the same by default and instead provide explicit tools to upgrade existing
|
|
75
|
+
lockfiles to new formats.
|
|
76
|
+
|
|
77
|
+
* Any documented methods in the RubyGems and Bundler namespaces, like
|
|
78
|
+
`Bundler.with_original_env` and similar.
|
|
79
|
+
|
|
80
|
+
* Actual APIs meant to be used by other libraries, like the plugin API.
|
|
81
|
+
|
|
82
|
+
* Entrypoints different from the CLI, like `bundler/setup` or
|
|
83
|
+
`bundler/inline`.
|
|
84
|
+
|
|
85
|
+
We will never intentionally break any of the above in patch or minor releases.
|
|
86
|
+
|
|
87
|
+
Internal classes and their methods (public or private) are not considered public
|
|
88
|
+
API, but we are aware that they are used in many places. So we try
|
|
89
|
+
not to break internal functionality that may be used by others, including proactively
|
|
90
|
+
using code search tools in public code. That said, we may not always be able to
|
|
91
|
+
avoid breaking things, and we may even intentionally introduce this kind of
|
|
92
|
+
"breakage" in a minor release if we deem it affects very few users or edge
|
|
93
|
+
cases. So be aware when using internals and ideally get in touch with us
|
|
94
|
+
before doing so, so that we can help find the right APIs.
|
|
95
|
+
|
|
96
|
+
## Discussing large changes
|
|
97
|
+
|
|
98
|
+
Large changes often benefit from being written out more completely, read by others, and discussed. [GitHub Discussions](https://github.com/ruby/rubygems/discussions) is the preferred place for that to happen.
|
|
99
|
+
|
|
100
|
+
## Committer Access
|
|
101
|
+
|
|
102
|
+
Committers may lose their commit privileges if they are inactive for longer than 12 months. Committer permission may be restored upon request by having a pull request merged.
|
|
103
|
+
|
|
104
|
+
This is designed to improve project maintainability by requiring committers to maintain familiarity with current development activity and to improve security by preventing idle committers from having their commit permissions compromised or exposed.
|
|
105
|
+
|
|
106
|
+
Always create pull requests rather than pushing directly to the primary branch. Try to get code review and merge approval from someone other than yourself whenever possible.
|
|
107
|
+
|
|
108
|
+
Contributors who have contributed regularly for more than six months (or implemented a completely new feature for a minor release) are eligible to join the maintainer team. Unless vetoed by an existing maintainer, these contributors will be asked to join the maintainer team. If they accept, new maintainers will be given permissions to view maintainer playbooks, accept pull requests, and release new versions.
|
|
109
|
+
|
|
110
|
+
## Enforcement guidelines
|
|
111
|
+
|
|
112
|
+
First off, these policies and their enforcement are subsidiary to the [code of conduct](https://github.com/ruby/rubygems/blob/master/CODE_OF_CONDUCT.md) in any case where they conflict. The first priority is treating human beings with respect and empathy, and figuring out project guidelines and sticking to them will always come after that.
|
|
113
|
+
|
|
114
|
+
When it comes to carrying out our own policies, we're all regular humans trying to do the best we can. There will probably be times when we don't stick to our policies or goals. If you notice a discrepancy between real-life actions and these policies and goals, please bring it up! We want to make sure that our actions and our policies line up, and that our policies exemplify our goals.
|
|
115
|
+
|
|
116
|
+
Policies are not set in stone, and may be revised if policy violations are found to be in the spirit of the project goals. Likewise, actions that violate the spirit of the project goals will be considered policy violations, and enforcement action will be taken. We're not interested in rules-lawyering, and we will take action when needed to ensure that everyone feels safe and included.
|
|
117
|
+
|
|
118
|
+
Please report policy violations by email to conduct@rubygems.org. Anyone violating a policy or goal is expected to cooperate with the team (and the reporter, if they request it) to resolve the issue in a way that follows the project goals.
|
|
119
|
+
|
|
120
|
+
## Team changes
|
|
121
|
+
|
|
122
|
+
### Adding a new team member
|
|
123
|
+
|
|
124
|
+
Interested in adding someone to the team? Here's the process.
|
|
125
|
+
|
|
126
|
+
1. An existing team member nominates a potential team member to the rest of the team.
|
|
127
|
+
2. The existing team reaches consensus about whether to invite the potential member.
|
|
128
|
+
3. The nominator asks the potential member if they would like to join the team.
|
|
129
|
+
4. The nominator also sends the candidate a link to [POLICIES](POLICIES.md) as an orientation for being on the team.
|
|
130
|
+
5. If the potential member accepts:
|
|
131
|
+
- Add them to the [maintainers list][team]
|
|
132
|
+
|
|
133
|
+
### Removing a team member
|
|
134
|
+
|
|
135
|
+
When team members choose to retire, here's how to remove someone from the team.
|
|
136
|
+
|
|
137
|
+
- Remove them from the [maintainers list][team]
|
|
138
|
+
|
|
139
|
+
## Changing These Policies
|
|
140
|
+
|
|
141
|
+
These policies were set in order to reduce the burden of maintenance and to keep
|
|
142
|
+
committers current with existing development and policies. RubyGems work is
|
|
143
|
+
primarily volunteer-driven which limits the ability to provide long-term
|
|
144
|
+
support. By joining [Ruby Central](https://rubycentral.org/#/portal/signup) you
|
|
145
|
+
can help extend support for older RubyGems versions.
|
|
146
|
+
|
|
147
|
+
[team]: https://guides.rubygems.org/contributing/#core-projects
|
data/doc/UPGRADING.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# How to upgrade/downgrade
|
|
1
|
+
# How to upgrade/downgrade RubyGems and Bundler:
|
|
2
2
|
|
|
3
3
|
## Upgrade Recipe
|
|
4
4
|
|
|
@@ -9,10 +9,10 @@
|
|
|
9
9
|
|
|
10
10
|
## Downgrade Recipe
|
|
11
11
|
|
|
12
|
-
$ gem update --system
|
|
12
|
+
$ gem update --system 4.0.20
|
|
13
13
|
|
|
14
|
-
$ gem install bundler -v
|
|
15
|
-
$ bundle update --bundler=
|
|
14
|
+
$ gem install bundler -v 4.0.20
|
|
15
|
+
$ bundle update --bundler=4.0.20
|
|
16
16
|
|
|
17
17
|
## Install a pre-release version
|
|
18
18
|
|
|
@@ -4,8 +4,8 @@ module Bundler
|
|
|
4
4
|
# Represents metadata from when the Bundler gem was built.
|
|
5
5
|
module BuildMetadata
|
|
6
6
|
# begin ivars
|
|
7
|
-
@built_at = "2026-09-
|
|
8
|
-
@git_commit_sha = "
|
|
7
|
+
@built_at = "2026-09-09".freeze
|
|
8
|
+
@git_commit_sha = "98e4d8083a7".freeze
|
|
9
9
|
# end ivars
|
|
10
10
|
|
|
11
11
|
# A hash representation of the build metadata.
|
|
@@ -187,83 +187,98 @@ module Bundler
|
|
|
187
187
|
# However, if the new checksum is from a different source, we register like normal.
|
|
188
188
|
# This ensures a mismatch error where there are multiple top level sources
|
|
189
189
|
# that contain the same gem with different checksums.
|
|
190
|
+
# The store is keyed by full name rather than lock name because a
|
|
191
|
+
# content-addressable build and the ordinary platform build of the same
|
|
192
|
+
# name, version, and platform share a lock name while being different
|
|
193
|
+
# files with different checksums.
|
|
190
194
|
def replace(spec, checksum)
|
|
191
195
|
return unless checksum
|
|
192
196
|
|
|
193
|
-
|
|
197
|
+
full_name = spec.full_name
|
|
194
198
|
@store_mutex.synchronize do
|
|
195
|
-
existing = fetch_checksum(
|
|
199
|
+
existing = fetch_checksum(full_name, checksum.algo)
|
|
196
200
|
if !existing || existing.same_source?(checksum)
|
|
197
|
-
store_checksum(
|
|
201
|
+
store_checksum(full_name, checksum)
|
|
198
202
|
else
|
|
199
|
-
merge_checksum(
|
|
203
|
+
merge_checksum(full_name, checksum, existing, spec.lock_name)
|
|
200
204
|
end
|
|
201
205
|
end
|
|
202
206
|
end
|
|
203
207
|
|
|
204
208
|
def missing?(spec)
|
|
205
|
-
@store[spec.
|
|
209
|
+
@store[spec.full_name].nil?
|
|
206
210
|
end
|
|
207
211
|
|
|
208
212
|
def empty?(spec)
|
|
209
213
|
return false unless spec.source.is_a?(Bundler::Source::Rubygems)
|
|
210
214
|
|
|
211
|
-
@store[spec.
|
|
215
|
+
@store[spec.full_name].empty?
|
|
212
216
|
end
|
|
213
217
|
|
|
214
218
|
def register(spec, checksum)
|
|
215
|
-
register_checksum(spec.
|
|
219
|
+
register_checksum(spec.full_name, checksum, spec.lock_name)
|
|
216
220
|
end
|
|
217
221
|
|
|
218
222
|
def merge!(other)
|
|
219
|
-
other.store.each do |
|
|
223
|
+
other.store.each do |full_name, checksums|
|
|
220
224
|
checksums.each do |_algo, checksum|
|
|
221
|
-
register_checksum(
|
|
225
|
+
register_checksum(full_name, checksum)
|
|
222
226
|
end
|
|
223
227
|
end
|
|
224
228
|
end
|
|
225
229
|
|
|
226
230
|
def to_lock(spec)
|
|
227
231
|
lock_name = spec.lock_name
|
|
228
|
-
checksums =
|
|
229
|
-
if checksums
|
|
230
|
-
"#{lock_name} #{checksums
|
|
232
|
+
checksums = checksums_to_lock(platform_full_name(spec))
|
|
233
|
+
if checksums
|
|
234
|
+
"#{lock_name} #{checksums}"
|
|
231
235
|
else
|
|
232
236
|
lock_name
|
|
233
237
|
end
|
|
234
238
|
end
|
|
235
239
|
|
|
240
|
+
def checksums_to_lock(full_name)
|
|
241
|
+
checksums = @store[full_name]
|
|
242
|
+
return unless checksums&.any?
|
|
243
|
+
|
|
244
|
+
checksums.values.map(&:to_lock).sort.join(",")
|
|
245
|
+
end
|
|
246
|
+
|
|
236
247
|
private
|
|
237
248
|
|
|
238
|
-
def
|
|
249
|
+
def platform_full_name(spec)
|
|
250
|
+
Gem::NameTuple.new(spec.name, spec.version, spec.platform).full_name
|
|
251
|
+
end
|
|
252
|
+
|
|
253
|
+
def register_checksum(full_name, checksum, display_name = full_name)
|
|
239
254
|
@store_mutex.synchronize do
|
|
240
255
|
if checksum
|
|
241
|
-
existing = fetch_checksum(
|
|
256
|
+
existing = fetch_checksum(full_name, checksum.algo)
|
|
242
257
|
if existing
|
|
243
|
-
merge_checksum(
|
|
258
|
+
merge_checksum(full_name, checksum, existing, display_name)
|
|
244
259
|
else
|
|
245
|
-
store_checksum(
|
|
260
|
+
store_checksum(full_name, checksum)
|
|
246
261
|
end
|
|
247
262
|
else
|
|
248
|
-
init_checksum(
|
|
263
|
+
init_checksum(full_name)
|
|
249
264
|
end
|
|
250
265
|
end
|
|
251
266
|
end
|
|
252
267
|
|
|
253
|
-
def merge_checksum(
|
|
254
|
-
existing.merge!(checksum) || raise(ChecksumMismatchError.new(
|
|
268
|
+
def merge_checksum(full_name, checksum, existing, display_name = full_name)
|
|
269
|
+
existing.merge!(checksum) || raise(ChecksumMismatchError.new(display_name, existing, checksum))
|
|
255
270
|
end
|
|
256
271
|
|
|
257
|
-
def store_checksum(
|
|
258
|
-
init_checksum(
|
|
272
|
+
def store_checksum(full_name, checksum)
|
|
273
|
+
init_checksum(full_name)[checksum.algo] = checksum
|
|
259
274
|
end
|
|
260
275
|
|
|
261
|
-
def init_checksum(
|
|
262
|
-
@store[
|
|
276
|
+
def init_checksum(full_name)
|
|
277
|
+
@store[full_name] ||= {}
|
|
263
278
|
end
|
|
264
279
|
|
|
265
|
-
def fetch_checksum(
|
|
266
|
-
@store[
|
|
280
|
+
def fetch_checksum(full_name, algo)
|
|
281
|
+
@store[full_name]&.fetch(algo, nil)
|
|
267
282
|
end
|
|
268
283
|
end
|
|
269
284
|
end
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
module Bundler
|
|
4
4
|
module CIDetector
|
|
5
5
|
# NOTE: Any changes made here will need to be made to both lib/rubygems/ci_detector.rb and
|
|
6
|
-
#
|
|
6
|
+
# lib/bundler/ci_detector.rb (which are enforced duplicates).
|
|
7
7
|
# TODO: Drop that duplication once bundler drops support for RubyGems 3.4
|
|
8
8
|
#
|
|
9
9
|
# ## Recognized CI providers, their signifiers, and the relevant docs ##
|
|
@@ -14,8 +14,7 @@ module Bundler
|
|
|
14
14
|
def run
|
|
15
15
|
Bundler.ui.level = "warn" if options[:quiet]
|
|
16
16
|
|
|
17
|
-
Bundler::CLI::Common.
|
|
18
|
-
Bundler.settings.set_command_option_if_given :cooldown, options[:cooldown]
|
|
17
|
+
Bundler::CLI::Common.configure_cooldown(options)
|
|
19
18
|
|
|
20
19
|
validate_options!
|
|
21
20
|
inject_dependencies
|
|
@@ -34,7 +33,7 @@ module Bundler
|
|
|
34
33
|
|
|
35
34
|
Injector.inject(dependencies,
|
|
36
35
|
conservative_versioning: options[:version].nil?, # Perform conservative versioning only when version is not specified
|
|
37
|
-
|
|
36
|
+
pessimistic: options[:pessimistic],
|
|
38
37
|
strict: options[:strict])
|
|
39
38
|
end
|
|
40
39
|
|
|
@@ -49,7 +48,7 @@ module Bundler
|
|
|
49
48
|
|
|
50
49
|
raise InvalidOption, "You cannot specify `--branch` and `--ref` at the same time." if options["branch"] && options["ref"]
|
|
51
50
|
|
|
52
|
-
raise InvalidOption, "You cannot specify `--strict` and `--
|
|
51
|
+
raise InvalidOption, "You cannot specify `--strict` and `--pessimistic` at the same time." if options[:strict] && options[:pessimistic]
|
|
53
52
|
|
|
54
53
|
# raise error when no gems are specified
|
|
55
54
|
raise InvalidOption, "Please specify gems to add." if gems.empty?
|
|
@@ -17,6 +17,8 @@ module Bundler
|
|
|
17
17
|
Bundler.settings.temporary(cache_all_platforms: options["all-platforms"]) do
|
|
18
18
|
Bundler.load.cache
|
|
19
19
|
end
|
|
20
|
+
|
|
21
|
+
Bundler::CLI::Common.prune
|
|
20
22
|
end
|
|
21
23
|
|
|
22
24
|
private
|
|
@@ -26,6 +28,8 @@ module Bundler
|
|
|
26
28
|
options = self.options.dup
|
|
27
29
|
options["local"] = false if Bundler.settings[:cache_all_platforms]
|
|
28
30
|
options["no-cache"] = true
|
|
31
|
+
options["skip-prune"] = true
|
|
32
|
+
options["cache-archives"] = true
|
|
29
33
|
Bundler::CLI::Install.new(options).run
|
|
30
34
|
end
|
|
31
35
|
end
|
|
@@ -11,6 +11,11 @@ module Bundler
|
|
|
11
11
|
def run
|
|
12
12
|
require_path_or_force unless options[:"dry-run"]
|
|
13
13
|
Bundler.load.clean(options[:"dry-run"])
|
|
14
|
+
return if options[:"dry-run"]
|
|
15
|
+
|
|
16
|
+
# Pruning last, because cleaning decides which cached .gem files are
|
|
17
|
+
# stale by reading them.
|
|
18
|
+
Bundler::CLI::Common.prune(options)
|
|
14
19
|
end
|
|
15
20
|
|
|
16
21
|
protected
|
|
@@ -2,12 +2,39 @@
|
|
|
2
2
|
|
|
3
3
|
module Bundler
|
|
4
4
|
module CLI::Common
|
|
5
|
+
# Validates the `--cooldown` flag and makes it the setting for this
|
|
6
|
+
# command. Every command that takes the flag goes through here, so they
|
|
7
|
+
# share one reading of the value.
|
|
8
|
+
def self.configure_cooldown(options)
|
|
9
|
+
value = options[:cooldown]
|
|
10
|
+
|
|
11
|
+
validate_cooldown!(value)
|
|
12
|
+
Bundler.settings.set_command_option_if_given :cooldown, value
|
|
13
|
+
end
|
|
14
|
+
|
|
5
15
|
def self.validate_cooldown!(value)
|
|
6
|
-
|
|
16
|
+
# Without the flag the config files, BUNDLE_COOLDOWN and the gemrc
|
|
17
|
+
# setting decide, and those only warn, so a typo left in a config file
|
|
18
|
+
# keeps the command usable.
|
|
19
|
+
return warn_invalid_cooldown_setting if value.nil?
|
|
7
20
|
return if value.is_a?(Integer) && value >= 0
|
|
8
21
|
raise InvalidOption, "Expected `--cooldown` to be a non-negative integer, got #{value.inspect}"
|
|
9
22
|
end
|
|
10
23
|
|
|
24
|
+
# A cooldown value that cannot be read as a non-negative integer takes no
|
|
25
|
+
# part in the resolution, so say so rather than letting the protection
|
|
26
|
+
# lapse quietly. The RubyGems `:cooldown:` setting feeds the same
|
|
27
|
+
# resolution and is checked in Bundler::Settings#rubygems_cooldown, where
|
|
28
|
+
# reading it is already being paid for.
|
|
29
|
+
def self.warn_invalid_cooldown_setting
|
|
30
|
+
require "rubygems/cooldown_settings"
|
|
31
|
+
|
|
32
|
+
value = Bundler.settings.locations(:cooldown).values.first
|
|
33
|
+
return unless Gem::CooldownSettings.invalid?(value)
|
|
34
|
+
|
|
35
|
+
Bundler.ui.warn Gem::CooldownSettings.invalid_message(value, "Bundler's configuration")
|
|
36
|
+
end
|
|
37
|
+
|
|
11
38
|
def self.output_post_install_messages(messages)
|
|
12
39
|
return if Bundler.settings["ignore_messages"]
|
|
13
40
|
messages.to_a.each do |name, msg|
|
|
@@ -155,6 +182,15 @@ module Bundler
|
|
|
155
182
|
clean
|
|
156
183
|
end
|
|
157
184
|
|
|
185
|
+
# `bundle cache` copies the gem files out of the cache after installing, so
|
|
186
|
+
# it asks to be skipped here and prunes once it is done.
|
|
187
|
+
def self.prune(options = {})
|
|
188
|
+
return if options["skip-prune"]
|
|
189
|
+
|
|
190
|
+
categories = Bundler.settings[:prune]
|
|
191
|
+
Bundler.load.prune(categories) unless categories.empty?
|
|
192
|
+
end
|
|
193
|
+
|
|
158
194
|
def self.word_list(words)
|
|
159
195
|
if words.empty?
|
|
160
196
|
return ""
|
|
@@ -97,7 +97,7 @@ module Bundler
|
|
|
97
97
|
confirm(name)
|
|
98
98
|
end
|
|
99
99
|
|
|
100
|
-
if current_value.nil?
|
|
100
|
+
if current_value.nil? && !Bundler.settings.stored_outside_config_files?(name)
|
|
101
101
|
exit 1
|
|
102
102
|
else
|
|
103
103
|
return
|
|
@@ -111,6 +111,8 @@ module Bundler
|
|
|
111
111
|
def confirm_all
|
|
112
112
|
if @options[:parseable]
|
|
113
113
|
thor.with_padding do
|
|
114
|
+
# --parseable output is fed back to `bundle config set`, where a
|
|
115
|
+
# placeholder would be read back as the credential itself.
|
|
114
116
|
Bundler.settings.all.each do |setting|
|
|
115
117
|
val = Bundler.settings[setting]
|
|
116
118
|
Bundler.ui.info "#{setting}=#{val}"
|
|
@@ -118,7 +120,7 @@ module Bundler
|
|
|
118
120
|
end
|
|
119
121
|
else
|
|
120
122
|
Bundler.ui.confirm "Settings are listed in order of priority. The top value will be used.\n"
|
|
121
|
-
Bundler.settings.
|
|
123
|
+
Bundler.settings.all_including_stored_credentials.each do |setting|
|
|
122
124
|
Bundler.ui.confirm setting
|
|
123
125
|
show_pretty_values_for(setting)
|
|
124
126
|
Bundler.ui.confirm ""
|
|
@@ -7,12 +7,6 @@ module Bundler
|
|
|
7
7
|
end
|
|
8
8
|
|
|
9
9
|
class CLI::Gem
|
|
10
|
-
TEST_FRAMEWORK_VERSIONS = {
|
|
11
|
-
"rspec" => "3.0",
|
|
12
|
-
"minitest" => "5.16",
|
|
13
|
-
"test-unit" => "3.0",
|
|
14
|
-
}.freeze
|
|
15
|
-
|
|
16
10
|
DEFAULT_GITHUB_USERNAME = "[USERNAME]"
|
|
17
11
|
|
|
18
12
|
attr_reader :options, :gem_name, :thor, :name, :target, :extension
|
|
@@ -117,7 +111,6 @@ module Bundler
|
|
|
117
111
|
|
|
118
112
|
if test_framework = ask_and_set_test_framework
|
|
119
113
|
config[:test] = test_framework
|
|
120
|
-
config[:test_framework_version] = TEST_FRAMEWORK_VERSIONS[test_framework]
|
|
121
114
|
|
|
122
115
|
case test_framework
|
|
123
116
|
when "rspec"
|
|
@@ -203,12 +196,10 @@ module Bundler
|
|
|
203
196
|
config[:linter] = ask_and_set_linter
|
|
204
197
|
case config[:linter]
|
|
205
198
|
when "rubocop"
|
|
206
|
-
config[:linter_version] = rubocop_version
|
|
207
199
|
Bundler.ui.info "RuboCop enabled in config"
|
|
208
200
|
templates.merge!("rubocop.yml.tt" => ".rubocop.yml")
|
|
209
201
|
config[:ignore_paths] << ".rubocop.yml"
|
|
210
202
|
when "standard"
|
|
211
|
-
config[:linter_version] = standard_version
|
|
212
203
|
Bundler.ui.info "Standard enabled in config"
|
|
213
204
|
templates.merge!("standard.yml.tt" => ".standard.yml")
|
|
214
205
|
config[:ignore_paths] << ".standard.yml"
|
|
@@ -471,14 +462,6 @@ module Bundler
|
|
|
471
462
|
"3.2.0"
|
|
472
463
|
end
|
|
473
464
|
|
|
474
|
-
def rubocop_version
|
|
475
|
-
"1.21"
|
|
476
|
-
end
|
|
477
|
-
|
|
478
|
-
def standard_version
|
|
479
|
-
"1.3"
|
|
480
|
-
end
|
|
481
|
-
|
|
482
465
|
def github_username(git_username)
|
|
483
466
|
if options[:github_username].nil?
|
|
484
467
|
git_username
|
|
@@ -38,7 +38,7 @@ module Bundler
|
|
|
38
38
|
|
|
39
39
|
Bundler::Fetcher.disable_endpoint = options["full-index"]
|
|
40
40
|
|
|
41
|
-
Plugin.gemfile_install(Bundler.default_gemfile) if Bundler.settings[:plugins]
|
|
41
|
+
Plugin.gemfile_install(Bundler.default_gemfile, Bundler.default_lockfile) if Bundler.settings[:plugins]
|
|
42
42
|
|
|
43
43
|
# For install we want to enable strict validation
|
|
44
44
|
# (rather than some optimizations we perform at app runtime).
|
|
@@ -69,6 +69,8 @@ module Bundler
|
|
|
69
69
|
if CLI::Common.clean_after_install?
|
|
70
70
|
require_relative "clean"
|
|
71
71
|
Bundler::CLI::Clean.new(options).run
|
|
72
|
+
else
|
|
73
|
+
CLI::Common.prune(options)
|
|
72
74
|
end
|
|
73
75
|
|
|
74
76
|
Bundler::CLI::Common.output_fund_metadata_summary
|
|
@@ -113,10 +115,7 @@ module Bundler
|
|
|
113
115
|
|
|
114
116
|
Bundler.settings.set_command_option_if_given :jobs, options["jobs"]
|
|
115
117
|
|
|
116
|
-
Bundler::CLI::Common.
|
|
117
|
-
Bundler.settings.set_command_option_if_given :cooldown, options["cooldown"]
|
|
118
|
-
|
|
119
|
-
Bundler.settings.set_command_option_if_given :no_prune, options["no-prune"]
|
|
118
|
+
Bundler::CLI::Common.configure_cooldown(options)
|
|
120
119
|
|
|
121
120
|
Bundler.settings.set_command_option_if_given :no_install, options["no-install"]
|
|
122
121
|
|