rubygems-update 2.6.4 → 2.6.5
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of rubygems-update might be problematic. Click here for more details.
- checksums.yaml +4 -4
- data/.travis.yml +18 -24
- data/CODE_OF_CONDUCT.md +2 -2
- data/CONTRIBUTING.rdoc +1 -1
- data/History.txt +30 -1
- data/Manifest.txt +233 -3
- data/Rakefile +30 -1
- data/appveyor.yml +0 -2
- data/bundler/CHANGELOG.md +2407 -0
- data/bundler/CODE_OF_CONDUCT.md +42 -0
- data/bundler/CONTRIBUTING.md +36 -0
- data/bundler/DEVELOPMENT.md +148 -0
- data/bundler/ISSUES.md +100 -0
- data/bundler/LICENSE.md +23 -0
- data/bundler/README.md +40 -0
- data/bundler/exe/bundle +35 -0
- data/bundler/exe/bundle_ruby +61 -0
- data/bundler/exe/bundler +22 -0
- data/bundler/lib/bundler.rb +455 -0
- data/bundler/lib/bundler/capistrano.rb +17 -0
- data/bundler/lib/bundler/cli.rb +497 -0
- data/bundler/lib/bundler/cli/binstubs.rb +40 -0
- data/bundler/lib/bundler/cli/cache.rb +35 -0
- data/bundler/lib/bundler/cli/check.rb +40 -0
- data/bundler/lib/bundler/cli/clean.rb +26 -0
- data/bundler/lib/bundler/cli/common.rb +56 -0
- data/bundler/lib/bundler/cli/config.rb +100 -0
- data/bundler/lib/bundler/cli/console.rb +39 -0
- data/bundler/lib/bundler/cli/exec.rb +82 -0
- data/bundler/lib/bundler/cli/gem.rb +214 -0
- data/bundler/lib/bundler/cli/init.rb +33 -0
- data/bundler/lib/bundler/cli/inject.rb +33 -0
- data/bundler/lib/bundler/cli/install.rb +225 -0
- data/bundler/lib/bundler/cli/lock.rb +48 -0
- data/bundler/lib/bundler/cli/open.rb +25 -0
- data/bundler/lib/bundler/cli/outdated.rb +151 -0
- data/bundler/lib/bundler/cli/package.rb +46 -0
- data/bundler/lib/bundler/cli/platform.rb +45 -0
- data/bundler/lib/bundler/cli/plugin.rb +23 -0
- data/bundler/lib/bundler/cli/show.rb +75 -0
- data/bundler/lib/bundler/cli/update.rb +72 -0
- data/bundler/lib/bundler/cli/viz.rb +27 -0
- data/bundler/lib/bundler/constants.rb +6 -0
- data/bundler/lib/bundler/current_ruby.rb +84 -0
- data/bundler/lib/bundler/definition.rb +744 -0
- data/bundler/lib/bundler/dep_proxy.rb +46 -0
- data/bundler/lib/bundler/dependency.rb +127 -0
- data/bundler/lib/bundler/deployment.rb +63 -0
- data/bundler/lib/bundler/deprecate.rb +16 -0
- data/bundler/lib/bundler/dsl.rb +512 -0
- data/bundler/lib/bundler/endpoint_specification.rb +129 -0
- data/bundler/lib/bundler/env.rb +83 -0
- data/bundler/lib/bundler/environment.rb +42 -0
- data/bundler/lib/bundler/environment_preserver.rb +38 -0
- data/bundler/lib/bundler/errors.rb +124 -0
- data/bundler/lib/bundler/fetcher.rb +304 -0
- data/bundler/lib/bundler/fetcher/base.rb +41 -0
- data/bundler/lib/bundler/fetcher/compact_index.rb +103 -0
- data/bundler/lib/bundler/fetcher/dependency.rb +92 -0
- data/bundler/lib/bundler/fetcher/downloader.rb +66 -0
- data/bundler/lib/bundler/fetcher/index.rb +51 -0
- data/bundler/lib/bundler/friendly_errors.rb +103 -0
- data/bundler/lib/bundler/gem_helper.rb +188 -0
- data/bundler/lib/bundler/gem_helpers.rb +32 -0
- data/bundler/lib/bundler/gem_remote_fetcher.rb +42 -0
- data/bundler/lib/bundler/gem_tasks.rb +6 -0
- data/bundler/lib/bundler/graph.rb +172 -0
- data/bundler/lib/bundler/index.rb +191 -0
- data/bundler/lib/bundler/injector.rb +63 -0
- data/bundler/lib/bundler/inline.rb +74 -0
- data/bundler/lib/bundler/installer.rb +217 -0
- data/bundler/lib/bundler/installer/gem_installer.rb +77 -0
- data/bundler/lib/bundler/installer/parallel_installer.rb +126 -0
- data/bundler/lib/bundler/installer/standalone.rb +52 -0
- data/bundler/lib/bundler/lazy_specification.rb +85 -0
- data/bundler/lib/bundler/lockfile_parser.rb +233 -0
- data/bundler/lib/bundler/match_platform.rb +14 -0
- data/bundler/lib/bundler/mirror.rb +218 -0
- data/bundler/lib/bundler/plugin.rb +156 -0
- data/bundler/lib/bundler/plugin/api.rb +56 -0
- data/bundler/lib/bundler/plugin/dsl.rb +29 -0
- data/bundler/lib/bundler/plugin/index.rb +88 -0
- data/bundler/lib/bundler/plugin/installer.rb +99 -0
- data/bundler/lib/bundler/plugin/installer/git.rb +38 -0
- data/bundler/lib/bundler/plugin/installer/rubygems.rb +27 -0
- data/bundler/lib/bundler/plugin/source_list.rb +24 -0
- data/bundler/lib/bundler/postit_trampoline.rb +57 -0
- data/bundler/lib/bundler/psyched_yaml.rb +27 -0
- data/bundler/lib/bundler/remote_specification.rb +85 -0
- data/bundler/lib/bundler/resolver.rb +368 -0
- data/bundler/lib/bundler/retry.rb +61 -0
- data/bundler/lib/bundler/ruby_dsl.rb +17 -0
- data/bundler/lib/bundler/ruby_version.rb +140 -0
- data/bundler/lib/bundler/rubygems_ext.rb +178 -0
- data/bundler/lib/bundler/rubygems_gem_installer.rb +10 -0
- data/bundler/lib/bundler/rubygems_integration.rb +710 -0
- data/bundler/lib/bundler/runtime.rb +282 -0
- data/bundler/lib/bundler/settings.rb +259 -0
- data/bundler/lib/bundler/setup.rb +28 -0
- data/bundler/lib/bundler/shared_helpers.rb +212 -0
- data/bundler/lib/bundler/similarity_detector.rb +62 -0
- data/bundler/lib/bundler/source.rb +37 -0
- data/bundler/lib/bundler/source/gemspec.rb +13 -0
- data/bundler/lib/bundler/source/git.rb +297 -0
- data/bundler/lib/bundler/source/git/git_proxy.rb +218 -0
- data/bundler/lib/bundler/source/path.rb +245 -0
- data/bundler/lib/bundler/source/path/installer.rb +44 -0
- data/bundler/lib/bundler/source/rubygems.rb +450 -0
- data/bundler/lib/bundler/source/rubygems/remote.rb +59 -0
- data/bundler/lib/bundler/source_list.rb +106 -0
- data/bundler/lib/bundler/spec_set.rb +157 -0
- data/bundler/lib/bundler/ssl_certs/.document +1 -0
- data/bundler/lib/bundler/ssl_certs/certificate_manager.rb +65 -0
- data/bundler/lib/bundler/ssl_certs/index.rubygems.org/GlobalSignRootCA.pem +21 -0
- data/bundler/lib/bundler/ssl_certs/rubygems.global.ssl.fastly.net/DigiCertHighAssuranceEVRootCA.pem +23 -0
- data/{lib/rubygems/ssl_certs/rubygems.org/AddTrustExternalCARoot-2048.pem → bundler/lib/bundler/ssl_certs/rubygems.org/AddTrustExternalCARoot.pem} +0 -0
- data/bundler/lib/bundler/stub_specification.rb +24 -0
- data/bundler/lib/bundler/templates/Executable +17 -0
- data/bundler/lib/bundler/templates/Executable.standalone +12 -0
- data/bundler/lib/bundler/templates/Gemfile +5 -0
- data/bundler/lib/bundler/templates/newgem/.travis.yml.tt +5 -0
- data/bundler/lib/bundler/templates/newgem/CODE_OF_CONDUCT.md.tt +74 -0
- data/bundler/lib/bundler/templates/newgem/Gemfile.tt +4 -0
- data/bundler/lib/bundler/templates/newgem/LICENSE.txt.tt +21 -0
- data/bundler/lib/bundler/templates/newgem/README.md.tt +41 -0
- data/bundler/lib/bundler/templates/newgem/Rakefile.tt +29 -0
- data/bundler/lib/bundler/templates/newgem/bin/console.tt +14 -0
- data/bundler/lib/bundler/templates/newgem/bin/setup.tt +8 -0
- data/bundler/lib/bundler/templates/newgem/exe/newgem.tt +3 -0
- data/bundler/lib/bundler/templates/newgem/ext/newgem/extconf.rb.tt +3 -0
- data/bundler/lib/bundler/templates/newgem/ext/newgem/newgem.c.tt +9 -0
- data/bundler/lib/bundler/templates/newgem/ext/newgem/newgem.h.tt +6 -0
- data/bundler/lib/bundler/templates/newgem/gitignore.tt +16 -0
- data/bundler/lib/bundler/templates/newgem/lib/newgem.rb.tt +12 -0
- data/bundler/lib/bundler/templates/newgem/lib/newgem/version.rb.tt +7 -0
- data/bundler/lib/bundler/templates/newgem/newgem.gemspec.tt +46 -0
- data/bundler/lib/bundler/templates/newgem/rspec.tt +2 -0
- data/bundler/lib/bundler/templates/newgem/spec/newgem_spec.rb.tt +11 -0
- data/bundler/lib/bundler/templates/newgem/spec/spec_helper.rb.tt +2 -0
- data/bundler/lib/bundler/templates/newgem/test/newgem_test.rb.tt +11 -0
- data/bundler/lib/bundler/templates/newgem/test/test_helper.rb.tt +4 -0
- data/bundler/lib/bundler/ui.rb +8 -0
- data/bundler/lib/bundler/ui/rg_proxy.rb +18 -0
- data/bundler/lib/bundler/ui/shell.rb +114 -0
- data/bundler/lib/bundler/ui/silent.rb +48 -0
- data/bundler/lib/bundler/uri_credentials_filter.rb +36 -0
- data/bundler/lib/bundler/vendor/compact_index_client/lib/compact_index_client.rb +79 -0
- data/bundler/lib/bundler/vendor/compact_index_client/lib/compact_index_client/cache.rb +98 -0
- data/bundler/lib/bundler/vendor/compact_index_client/lib/compact_index_client/updater.rb +80 -0
- data/bundler/lib/bundler/vendor/compact_index_client/lib/compact_index_client/version.rb +4 -0
- data/bundler/lib/bundler/vendor/molinillo/lib/molinillo.rb +10 -0
- data/bundler/lib/bundler/vendor/molinillo/lib/molinillo/delegates/resolution_state.rb +50 -0
- data/bundler/lib/bundler/vendor/molinillo/lib/molinillo/delegates/specification_provider.rb +80 -0
- data/bundler/lib/bundler/vendor/molinillo/lib/molinillo/dependency_graph.rb +203 -0
- data/bundler/lib/bundler/vendor/molinillo/lib/molinillo/dependency_graph/action.rb +35 -0
- data/bundler/lib/bundler/vendor/molinillo/lib/molinillo/dependency_graph/add_edge_no_circular.rb +58 -0
- data/bundler/lib/bundler/vendor/molinillo/lib/molinillo/dependency_graph/add_vertex.rb +61 -0
- data/bundler/lib/bundler/vendor/molinillo/lib/molinillo/dependency_graph/detach_vertex_named.rb +53 -0
- data/bundler/lib/bundler/vendor/molinillo/lib/molinillo/dependency_graph/log.rb +114 -0
- data/bundler/lib/bundler/vendor/molinillo/lib/molinillo/dependency_graph/set_payload.rb +45 -0
- data/bundler/lib/bundler/vendor/molinillo/lib/molinillo/dependency_graph/tag.rb +35 -0
- data/bundler/lib/bundler/vendor/molinillo/lib/molinillo/dependency_graph/vertex.rb +123 -0
- data/bundler/lib/bundler/vendor/molinillo/lib/molinillo/errors.rb +75 -0
- data/bundler/lib/bundler/vendor/molinillo/lib/molinillo/gem_metadata.rb +5 -0
- data/bundler/lib/bundler/vendor/molinillo/lib/molinillo/modules/specification_provider.rb +100 -0
- data/bundler/lib/bundler/vendor/molinillo/lib/molinillo/modules/ui.rb +65 -0
- data/bundler/lib/bundler/vendor/molinillo/lib/molinillo/resolution.rb +460 -0
- data/bundler/lib/bundler/vendor/molinillo/lib/molinillo/resolver.rb +45 -0
- data/bundler/lib/bundler/vendor/molinillo/lib/molinillo/state.rb +54 -0
- data/bundler/lib/bundler/vendor/net/http/faster.rb +26 -0
- data/bundler/lib/bundler/vendor/net/http/persistent.rb +1230 -0
- data/bundler/lib/bundler/vendor/net/http/persistent/ssl_reuse.rb +128 -0
- data/bundler/lib/bundler/vendor/postit/lib/postit.rb +15 -0
- data/bundler/lib/bundler/vendor/postit/lib/postit/environment.rb +44 -0
- data/bundler/lib/bundler/vendor/postit/lib/postit/installer.rb +28 -0
- data/bundler/lib/bundler/vendor/postit/lib/postit/parser.rb +21 -0
- data/bundler/lib/bundler/vendor/postit/lib/postit/setup.rb +12 -0
- data/bundler/lib/bundler/vendor/postit/lib/postit/version.rb +3 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor.rb +484 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/actions.rb +319 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/actions/create_file.rb +103 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/actions/create_link.rb +59 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/actions/directory.rb +118 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/actions/empty_directory.rb +135 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/actions/file_manipulation.rb +316 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/actions/inject_into_file.rb +107 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/base.rb +656 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/command.rb +133 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/core_ext/hash_with_indifferent_access.rb +77 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/core_ext/io_binary_read.rb +10 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/core_ext/ordered_hash.rb +98 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/error.rb +32 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/group.rb +281 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/invocation.rb +178 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/line_editor.rb +17 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/line_editor/basic.rb +35 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/line_editor/readline.rb +88 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/parser.rb +4 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/parser/argument.rb +73 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/parser/arguments.rb +175 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/parser/option.rb +125 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/parser/options.rb +218 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/rake_compat.rb +71 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/runner.rb +322 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/shell.rb +81 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/shell/basic.rb +421 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/shell/color.rb +149 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/shell/html.rb +126 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/util.rb +267 -0
- data/bundler/lib/bundler/vendor/thor/lib/thor/version.rb +3 -0
- data/bundler/lib/bundler/vendored_molinillo.rb +3 -0
- data/bundler/lib/bundler/vendored_persistent.rb +12 -0
- data/bundler/lib/bundler/vendored_thor.rb +4 -0
- data/bundler/lib/bundler/version.rb +11 -0
- data/bundler/lib/bundler/vlad.rb +12 -0
- data/bundler/lib/bundler/worker.rb +82 -0
- data/bundler/lib/bundler/yaml_serializer.rb +67 -0
- data/bundler/man/bundle-config.ronn +193 -0
- data/bundler/man/bundle-exec.ronn +136 -0
- data/bundler/man/bundle-gem.ronn +77 -0
- data/bundler/man/bundle-install.ronn +404 -0
- data/bundler/man/bundle-lock.ronn +47 -0
- data/bundler/man/bundle-package.ronn +67 -0
- data/bundler/man/bundle-platform.ronn +42 -0
- data/bundler/man/bundle-update.ronn +194 -0
- data/bundler/man/bundle.ronn +98 -0
- data/bundler/man/gemfile.5.ronn +499 -0
- data/bundler/man/index.txt +8 -0
- data/lib/rubygems.rb +42 -2
- data/lib/rubygems/config_file.rb +1 -1
- data/lib/rubygems/defaults.rb +18 -0
- data/lib/rubygems/installer.rb +1 -0
- data/lib/rubygems/package.rb +3 -1
- data/lib/rubygems/package/tar_writer.rb +10 -16
- data/lib/rubygems/remote_fetcher.rb +1 -15
- data/lib/rubygems/resolver/molinillo/lib/molinillo/delegates/resolution_state.rb +50 -0
- data/lib/rubygems/resolver/molinillo/lib/molinillo/delegates/specification_provider.rb +80 -0
- data/lib/rubygems/resolver/molinillo/lib/molinillo/dependency_graph.rb +57 -145
- data/lib/rubygems/resolver/molinillo/lib/molinillo/dependency_graph/action.rb +35 -0
- data/lib/rubygems/resolver/molinillo/lib/molinillo/dependency_graph/add_edge_no_circular.rb +58 -0
- data/lib/rubygems/resolver/molinillo/lib/molinillo/dependency_graph/add_vertex.rb +61 -0
- data/lib/rubygems/resolver/molinillo/lib/molinillo/dependency_graph/detach_vertex_named.rb +53 -0
- data/lib/rubygems/resolver/molinillo/lib/molinillo/dependency_graph/log.rb +114 -0
- data/lib/rubygems/resolver/molinillo/lib/molinillo/dependency_graph/set_payload.rb +45 -0
- data/lib/rubygems/resolver/molinillo/lib/molinillo/dependency_graph/tag.rb +35 -0
- data/lib/rubygems/resolver/molinillo/lib/molinillo/dependency_graph/vertex.rb +123 -0
- data/lib/rubygems/resolver/molinillo/lib/molinillo/errors.rb +1 -1
- data/lib/rubygems/resolver/molinillo/lib/molinillo/gem_metadata.rb +1 -1
- data/lib/rubygems/resolver/molinillo/lib/molinillo/resolution.rb +55 -54
- data/lib/rubygems/resolver/molinillo/lib/molinillo/state.rb +4 -2
- data/lib/rubygems/security/signer.rb +2 -0
- data/lib/rubygems/specification.rb +4 -4
- data/lib/rubygems/ssl_certs/index.rubygems.org/GlobalSignRootCA.pem +21 -0
- data/lib/rubygems/ssl_certs/rubygems.org/AddTrustExternalCARoot.pem +25 -0
- data/test/rubygems/alternate_cert.pem +10 -9
- data/test/rubygems/alternate_cert_32.pem +10 -9
- data/test/rubygems/child_cert.pem +11 -9
- data/test/rubygems/child_cert_32.pem +11 -9
- data/test/rubygems/encrypted_private_key.pem +26 -26
- data/test/rubygems/expired_cert.pem +9 -8
- data/test/rubygems/future_cert.pem +9 -8
- data/test/rubygems/future_cert_32.pem +9 -8
- data/test/rubygems/grandchild_cert.pem +11 -9
- data/test/rubygems/grandchild_cert_32.pem +11 -9
- data/test/rubygems/invalid_issuer_cert.pem +11 -9
- data/test/rubygems/invalid_issuer_cert_32.pem +11 -9
- data/test/rubygems/invalid_signer_cert.pem +10 -9
- data/test/rubygems/invalid_signer_cert_32.pem +10 -9
- data/test/rubygems/invalidchild_cert.pem +11 -9
- data/test/rubygems/invalidchild_cert_32.pem +11 -9
- data/test/rubygems/public_cert.pem +11 -9
- data/test/rubygems/public_cert_32.pem +10 -9
- data/test/rubygems/test_bundled_ca.rb +1 -1
- data/test/rubygems/test_gem.rb +7 -0
- data/test/rubygems/test_gem_installer.rb +119 -0
- data/test/rubygems/test_gem_package.rb +9 -3
- data/test/rubygems/test_gem_package_tar_writer.rb +24 -0
- data/test/rubygems/test_gem_remote_fetcher.rb +0 -12
- data/test/rubygems/test_gem_security_signer.rb +8 -0
- data/test/rubygems/test_gem_specification.rb +1 -1
- data/test/rubygems/wrong_key_cert.pem +10 -9
- data/test/rubygems/wrong_key_cert_32.pem +10 -9
- data/util/ci +73 -0
- data/util/create_certs.rb +64 -49
- data/util/update_bundled_ca_certificates.rb +23 -2
- metadata +257 -19
- data/lib/gauntlet_rubygems.rb +0 -51
- data/lib/rubygems/ssl_certs/index.rubygems.org/GlobalSignRoot.pem +0 -18
@@ -0,0 +1,27 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Bundler
|
4
|
+
module Plugin
|
5
|
+
class Installer
|
6
|
+
class Rubygems < Bundler::Source::Rubygems
|
7
|
+
def version_message(spec)
|
8
|
+
"#{spec.name} #{spec.version}"
|
9
|
+
end
|
10
|
+
|
11
|
+
private
|
12
|
+
|
13
|
+
def requires_sudo?
|
14
|
+
false # Will change on implementation of project level plugins
|
15
|
+
end
|
16
|
+
|
17
|
+
def rubygems_dir
|
18
|
+
Plugin.root
|
19
|
+
end
|
20
|
+
|
21
|
+
def cache_path
|
22
|
+
Plugin.cache
|
23
|
+
end
|
24
|
+
end
|
25
|
+
end
|
26
|
+
end
|
27
|
+
end
|
@@ -0,0 +1,24 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Bundler
|
4
|
+
# SourceList object to be used while parsing the Gemfile, setting the
|
5
|
+
# approptiate options to be used with Source classes for plugin installation
|
6
|
+
module Plugin
|
7
|
+
class SourceList < Bundler::SourceList
|
8
|
+
def initialize
|
9
|
+
@path_sources = []
|
10
|
+
@git_sources = []
|
11
|
+
@rubygems_aggregate = Plugin::Installer::Rubygems.new
|
12
|
+
@rubygems_sources = []
|
13
|
+
end
|
14
|
+
|
15
|
+
def add_git_source(options = {})
|
16
|
+
add_source_to_list Plugin::Installer::Git.new(options), git_sources
|
17
|
+
end
|
18
|
+
|
19
|
+
def add_rubygems_source(options = {})
|
20
|
+
add_source_to_list Plugin::Installer::Rubygems.new(options), @rubygems_sources
|
21
|
+
end
|
22
|
+
end
|
23
|
+
end
|
24
|
+
end
|
@@ -0,0 +1,57 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
postit_lib = File.expand_path("../vendor/postit/lib", __FILE__)
|
4
|
+
$:.unshift(postit_lib)
|
5
|
+
require "postit"
|
6
|
+
require "rubygems"
|
7
|
+
|
8
|
+
environment = BundlerVendoredPostIt::Environment.new([])
|
9
|
+
version = Gem::Requirement.new(environment.bundler_version)
|
10
|
+
|
11
|
+
installed_version =
|
12
|
+
if defined?(Bundler::VERSION)
|
13
|
+
Bundler::VERSION
|
14
|
+
else
|
15
|
+
File.read(File.expand_path("../version.rb", __FILE__)) =~ /VERSION = "(.+)"/
|
16
|
+
$1
|
17
|
+
end
|
18
|
+
installed_version &&= Gem::Version.new(installed_version)
|
19
|
+
|
20
|
+
if !version.satisfied_by?(installed_version)
|
21
|
+
begin
|
22
|
+
installer = BundlerVendoredPostIt::Installer.new(version)
|
23
|
+
installer.install!
|
24
|
+
rescue => e
|
25
|
+
abort <<-EOS.strip
|
26
|
+
Installing the inferred bundler version (#{version}) failed.
|
27
|
+
If you'd like to update to the current bundler version (#{installed_version}) in this project, run `bundle update --bundler`.
|
28
|
+
The error was: #{e}
|
29
|
+
EOS
|
30
|
+
end
|
31
|
+
|
32
|
+
if deleted_spec = Gem.loaded_specs.delete("bundler")
|
33
|
+
deleted_spec.full_require_paths.each {|path| $:.delete(path) }
|
34
|
+
else
|
35
|
+
$:.delete(File.expand_path("../..", __FILE__))
|
36
|
+
end
|
37
|
+
gem "bundler", version
|
38
|
+
else
|
39
|
+
begin
|
40
|
+
gem "bundler", version
|
41
|
+
rescue LoadError
|
42
|
+
$:.unshift(File.expand_path("../..", __FILE__))
|
43
|
+
end
|
44
|
+
end
|
45
|
+
|
46
|
+
running_version = begin
|
47
|
+
require "bundler/version"
|
48
|
+
Bundler::VERSION
|
49
|
+
rescue LoadError, NameError
|
50
|
+
nil
|
51
|
+
end
|
52
|
+
|
53
|
+
if !Gem::Version.correct?(running_version.to_s) || !version.satisfied_by?(Gem::Version.create(running_version))
|
54
|
+
abort "The running bundler (#{running_version}) does not match the required `#{version}`"
|
55
|
+
end
|
56
|
+
|
57
|
+
$:.delete_at($:.find_index(postit_lib))
|
@@ -0,0 +1,27 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
# Psych could be a gem, so try to ask for it
|
3
|
+
begin
|
4
|
+
gem "psych"
|
5
|
+
rescue LoadError
|
6
|
+
end if defined?(gem)
|
7
|
+
|
8
|
+
# Psych could be in the stdlib
|
9
|
+
# but it's too late if Syck is already loaded
|
10
|
+
begin
|
11
|
+
require "psych" unless defined?(Syck)
|
12
|
+
rescue LoadError
|
13
|
+
# Apparently Psych wasn't available. Oh well.
|
14
|
+
end
|
15
|
+
|
16
|
+
# At least load the YAML stdlib, whatever that may be
|
17
|
+
require "yaml" unless defined?(YAML.dump)
|
18
|
+
|
19
|
+
module Bundler
|
20
|
+
# On encountering invalid YAML,
|
21
|
+
# Psych raises Psych::SyntaxError
|
22
|
+
if defined?(::Psych::SyntaxError)
|
23
|
+
YamlLibrarySyntaxError = ::Psych::SyntaxError
|
24
|
+
else # Syck raises ArgumentError
|
25
|
+
YamlLibrarySyntaxError = ::ArgumentError
|
26
|
+
end
|
27
|
+
end
|
@@ -0,0 +1,85 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
require "uri"
|
3
|
+
require "rubygems/spec_fetcher"
|
4
|
+
|
5
|
+
module Bundler
|
6
|
+
# Represents a lazily loaded gem specification, where the full specification
|
7
|
+
# is on the source server in rubygems' "quick" index. The proxy object is to
|
8
|
+
# be seeded with what we're given from the source's abbreviated index - the
|
9
|
+
# full specification will only be fetched when necessary.
|
10
|
+
class RemoteSpecification
|
11
|
+
include MatchPlatform
|
12
|
+
include Comparable
|
13
|
+
|
14
|
+
attr_reader :name, :version, :platform
|
15
|
+
attr_accessor :source, :remote
|
16
|
+
|
17
|
+
def initialize(name, version, platform, spec_fetcher)
|
18
|
+
@name = name
|
19
|
+
@version = Gem::Version.create version
|
20
|
+
@platform = platform
|
21
|
+
@spec_fetcher = spec_fetcher
|
22
|
+
end
|
23
|
+
|
24
|
+
# Needed before installs, since the arch matters then and quick
|
25
|
+
# specs don't bother to include the arch in the platform string
|
26
|
+
def fetch_platform
|
27
|
+
@platform = _remote_specification.platform
|
28
|
+
end
|
29
|
+
|
30
|
+
def full_name
|
31
|
+
if platform == Gem::Platform::RUBY || platform.nil?
|
32
|
+
"#{@name}-#{@version}"
|
33
|
+
else
|
34
|
+
"#{@name}-#{@version}-#{platform}"
|
35
|
+
end
|
36
|
+
end
|
37
|
+
|
38
|
+
# Compare this specification against another object. Using sort_obj
|
39
|
+
# is compatible with Gem::Specification and other Bundler or RubyGems
|
40
|
+
# objects. Otherwise, use the default Object comparison.
|
41
|
+
def <=>(other)
|
42
|
+
if other.respond_to?(:sort_obj)
|
43
|
+
sort_obj <=> other.sort_obj
|
44
|
+
else
|
45
|
+
super
|
46
|
+
end
|
47
|
+
end
|
48
|
+
|
49
|
+
# Because Rubyforge cannot be trusted to provide valid specifications
|
50
|
+
# once the remote gem is downloaded, the backend specification will
|
51
|
+
# be swapped out.
|
52
|
+
def __swap__(spec)
|
53
|
+
@_remote_specification = spec
|
54
|
+
end
|
55
|
+
|
56
|
+
# Create a delegate used for sorting. This strategy is copied from
|
57
|
+
# RubyGems 2.23 and ensures that Bundler's specifications can be
|
58
|
+
# compared and sorted with RubyGems' own specifications.
|
59
|
+
#
|
60
|
+
# @see #<=>
|
61
|
+
# @see Gem::Specification#sort_obj
|
62
|
+
#
|
63
|
+
# @return [Array] an object you can use to compare and sort this
|
64
|
+
# specification against other specifications
|
65
|
+
def sort_obj
|
66
|
+
[@name, @version, @platform == Gem::Platform::RUBY ? -1 : 1]
|
67
|
+
end
|
68
|
+
|
69
|
+
def to_s
|
70
|
+
"#<#{self.class} name=#{name} version=#{version} platform=#{platform}>"
|
71
|
+
end
|
72
|
+
|
73
|
+
private
|
74
|
+
|
75
|
+
def _remote_specification
|
76
|
+
@_remote_specification ||= @spec_fetcher.fetch_spec([@name, @version, @platform])
|
77
|
+
@_remote_specification || raise(GemspecError, "Gemspec data for #{full_name} was" \
|
78
|
+
" missing from the server! Try installing with `--full-index` as a workaround.")
|
79
|
+
end
|
80
|
+
|
81
|
+
def method_missing(method, *args, &blk)
|
82
|
+
_remote_specification.send(method, *args, &blk)
|
83
|
+
end
|
84
|
+
end
|
85
|
+
end
|
@@ -0,0 +1,368 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
module Bundler
|
3
|
+
class Resolver
|
4
|
+
require "bundler/vendored_molinillo"
|
5
|
+
|
6
|
+
class Molinillo::VersionConflict
|
7
|
+
def printable_dep(dep)
|
8
|
+
if dep.is_a?(Bundler::Dependency)
|
9
|
+
DepProxy.new(dep, dep.platforms.join(", ")).to_s.strip
|
10
|
+
else
|
11
|
+
dep.to_s
|
12
|
+
end
|
13
|
+
end
|
14
|
+
|
15
|
+
def message
|
16
|
+
conflicts.sort.reduce(String.new) do |o, (name, conflict)|
|
17
|
+
o << %(Bundler could not find compatible versions for gem "#{name}":\n)
|
18
|
+
if conflict.locked_requirement
|
19
|
+
o << %( In snapshot (#{Bundler.default_lockfile.basename}):\n)
|
20
|
+
o << %( #{printable_dep(conflict.locked_requirement)}\n)
|
21
|
+
o << %(\n)
|
22
|
+
end
|
23
|
+
o << %( In Gemfile:\n)
|
24
|
+
o << conflict.requirement_trees.sort_by {|t| t.reverse.map(&:name) }.map do |tree|
|
25
|
+
t = String.new
|
26
|
+
depth = 2
|
27
|
+
tree.each do |req|
|
28
|
+
t << " " * depth << req.to_s
|
29
|
+
unless tree.last == req
|
30
|
+
if spec = conflict.activated_by_name[req.name]
|
31
|
+
t << %( was resolved to #{spec.version}, which)
|
32
|
+
end
|
33
|
+
t << %( depends on)
|
34
|
+
end
|
35
|
+
t << %(\n)
|
36
|
+
depth += 1
|
37
|
+
end
|
38
|
+
t
|
39
|
+
end.join("\n")
|
40
|
+
|
41
|
+
if name == "bundler"
|
42
|
+
o << %(\n Current Bundler version:\n bundler (#{Bundler::VERSION}))
|
43
|
+
other_bundler_required = !conflict.requirement.requirement.satisfied_by?(Gem::Version.new Bundler::VERSION)
|
44
|
+
end
|
45
|
+
|
46
|
+
if name == "bundler" && other_bundler_required
|
47
|
+
o << "\n"
|
48
|
+
o << "This Gemfile requires a different version of Bundler.\n"
|
49
|
+
o << "Perhaps you need to update Bundler by running `gem install bundler`?\n"
|
50
|
+
end
|
51
|
+
if conflict.locked_requirement
|
52
|
+
o << "\n"
|
53
|
+
o << %(Running `bundle update` will rebuild your snapshot from scratch, using only\n)
|
54
|
+
o << %(the gems in your Gemfile, which may resolve the conflict.\n)
|
55
|
+
elsif !conflict.existing
|
56
|
+
o << "\n"
|
57
|
+
if conflict.requirement_trees.first.size > 1
|
58
|
+
o << "Could not find gem '#{conflict.requirement}', which is required by "
|
59
|
+
o << "gem '#{conflict.requirement_trees.first[-2]}', in any of the sources."
|
60
|
+
else
|
61
|
+
o << "Could not find gem '#{conflict.requirement}' in any of the sources\n"
|
62
|
+
end
|
63
|
+
end
|
64
|
+
o
|
65
|
+
end
|
66
|
+
end
|
67
|
+
end
|
68
|
+
|
69
|
+
ALL = Bundler::Dependency::PLATFORM_MAP.values.uniq.freeze
|
70
|
+
|
71
|
+
class SpecGroup < Array
|
72
|
+
include GemHelpers
|
73
|
+
|
74
|
+
attr_reader :activated, :required_by
|
75
|
+
|
76
|
+
def initialize(a)
|
77
|
+
super
|
78
|
+
@required_by = []
|
79
|
+
@activated = []
|
80
|
+
@dependencies = nil
|
81
|
+
@specs = {}
|
82
|
+
|
83
|
+
ALL.each do |p|
|
84
|
+
@specs[p] = reverse.find {|s| s.match_platform(p) }
|
85
|
+
end
|
86
|
+
end
|
87
|
+
|
88
|
+
def initialize_copy(o)
|
89
|
+
super
|
90
|
+
@required_by = o.required_by.dup
|
91
|
+
@activated = o.activated.dup
|
92
|
+
end
|
93
|
+
|
94
|
+
def to_specs
|
95
|
+
specs = {}
|
96
|
+
|
97
|
+
@activated.each do |p|
|
98
|
+
next unless s = @specs[p]
|
99
|
+
platform = generic(Gem::Platform.new(s.platform))
|
100
|
+
next if specs[platform]
|
101
|
+
|
102
|
+
lazy_spec = LazySpecification.new(name, version, platform, source)
|
103
|
+
lazy_spec.dependencies.replace s.dependencies
|
104
|
+
specs[platform] = lazy_spec
|
105
|
+
end
|
106
|
+
specs.values
|
107
|
+
end
|
108
|
+
|
109
|
+
def activate_platform!(platform)
|
110
|
+
@activated << platform if !@activated.include?(platform) && for?(platform, nil)
|
111
|
+
end
|
112
|
+
|
113
|
+
def name
|
114
|
+
@name ||= first.name
|
115
|
+
end
|
116
|
+
|
117
|
+
def version
|
118
|
+
@version ||= first.version
|
119
|
+
end
|
120
|
+
|
121
|
+
def source
|
122
|
+
@source ||= first.source
|
123
|
+
end
|
124
|
+
|
125
|
+
def for?(platform, required_ruby_version)
|
126
|
+
if spec = @specs[platform]
|
127
|
+
if required_ruby_version && spec.respond_to?(:required_ruby_version) && spec_required_ruby_version = spec.required_ruby_version
|
128
|
+
spec_required_ruby_version.satisfied_by?(required_ruby_version.to_gem_version_with_patchlevel)
|
129
|
+
else
|
130
|
+
true
|
131
|
+
end
|
132
|
+
end
|
133
|
+
end
|
134
|
+
|
135
|
+
def to_s
|
136
|
+
"#{name} (#{version})"
|
137
|
+
end
|
138
|
+
|
139
|
+
def dependencies_for_activated_platforms
|
140
|
+
@activated.map {|p| __dependencies[p] }.flatten
|
141
|
+
end
|
142
|
+
|
143
|
+
def platforms_for_dependency_named(dependency)
|
144
|
+
__dependencies.select {|_, deps| deps.map(&:name).include? dependency }.keys
|
145
|
+
end
|
146
|
+
|
147
|
+
private
|
148
|
+
|
149
|
+
def __dependencies
|
150
|
+
@dependencies ||= begin
|
151
|
+
dependencies = {}
|
152
|
+
ALL.each do |p|
|
153
|
+
next unless spec = @specs[p]
|
154
|
+
dependencies[p] = []
|
155
|
+
spec.dependencies.each do |dep|
|
156
|
+
next if dep.type == :development
|
157
|
+
dependencies[p] << DepProxy.new(dep, p)
|
158
|
+
end
|
159
|
+
end
|
160
|
+
dependencies
|
161
|
+
end
|
162
|
+
end
|
163
|
+
end
|
164
|
+
|
165
|
+
# Figures out the best possible configuration of gems that satisfies
|
166
|
+
# the list of passed dependencies and any child dependencies without
|
167
|
+
# causing any gem activation errors.
|
168
|
+
#
|
169
|
+
# ==== Parameters
|
170
|
+
# *dependencies<Gem::Dependency>:: The list of dependencies to resolve
|
171
|
+
#
|
172
|
+
# ==== Returns
|
173
|
+
# <GemBundle>,nil:: If the list of dependencies can be resolved, a
|
174
|
+
# collection of gemspecs is returned. Otherwise, nil is returned.
|
175
|
+
def self.resolve(requirements, index, source_requirements = {}, base = [], ruby_version = nil)
|
176
|
+
base = SpecSet.new(base) unless base.is_a?(SpecSet)
|
177
|
+
resolver = new(index, source_requirements, base, ruby_version)
|
178
|
+
result = resolver.start(requirements)
|
179
|
+
SpecSet.new(result)
|
180
|
+
end
|
181
|
+
|
182
|
+
def initialize(index, source_requirements, base, ruby_version)
|
183
|
+
@index = index
|
184
|
+
@source_requirements = source_requirements
|
185
|
+
@base = base
|
186
|
+
@resolver = Molinillo::Resolver.new(self, self)
|
187
|
+
@search_for = {}
|
188
|
+
@base_dg = Molinillo::DependencyGraph.new
|
189
|
+
@base.each {|ls| @base_dg.add_vertex(ls.name, Dependency.new(ls.name, ls.version), true) }
|
190
|
+
@ruby_version = ruby_version
|
191
|
+
end
|
192
|
+
|
193
|
+
def start(requirements)
|
194
|
+
verify_gemfile_dependencies_are_found!(requirements)
|
195
|
+
dg = @resolver.resolve(requirements, @base_dg)
|
196
|
+
dg.map(&:payload).map(&:to_specs).flatten
|
197
|
+
rescue Molinillo::VersionConflict => e
|
198
|
+
raise VersionConflict.new(e.conflicts.keys.uniq, e.message)
|
199
|
+
rescue Molinillo::CircularDependencyError => e
|
200
|
+
names = e.dependencies.sort_by(&:name).map {|d| "gem '#{d.name}'" }
|
201
|
+
raise CyclicDependencyError, "Your bundle requires gems that depend" \
|
202
|
+
" on each other, creating an infinite loop. Please remove" \
|
203
|
+
" #{names.count > 1 ? "either " : ""}#{names.join(" or ")}" \
|
204
|
+
" and try again."
|
205
|
+
end
|
206
|
+
|
207
|
+
include Molinillo::UI
|
208
|
+
|
209
|
+
# Conveys debug information to the user.
|
210
|
+
#
|
211
|
+
# @param [Integer] depth the current depth of the resolution process.
|
212
|
+
# @return [void]
|
213
|
+
def debug(depth = 0)
|
214
|
+
return unless debug?
|
215
|
+
debug_info = yield
|
216
|
+
debug_info = debug_info.inspect unless debug_info.is_a?(String)
|
217
|
+
STDERR.puts debug_info.split("\n").map {|s| " " * depth + s }
|
218
|
+
end
|
219
|
+
|
220
|
+
def debug?
|
221
|
+
return @debug_mode if defined?(@debug_mode)
|
222
|
+
@debug_mode = ENV["DEBUG_RESOLVER"] || ENV["DEBUG_RESOLVER_TREE"]
|
223
|
+
end
|
224
|
+
|
225
|
+
def before_resolution
|
226
|
+
Bundler.ui.info "Resolving dependencies...", false
|
227
|
+
end
|
228
|
+
|
229
|
+
def after_resolution
|
230
|
+
Bundler.ui.info ""
|
231
|
+
end
|
232
|
+
|
233
|
+
def indicate_progress
|
234
|
+
Bundler.ui.info ".", false
|
235
|
+
end
|
236
|
+
|
237
|
+
include Molinillo::SpecificationProvider
|
238
|
+
|
239
|
+
def dependencies_for(specification)
|
240
|
+
specification.dependencies_for_activated_platforms
|
241
|
+
end
|
242
|
+
|
243
|
+
def search_for(dependency)
|
244
|
+
platform = dependency.__platform
|
245
|
+
dependency = dependency.dep unless dependency.is_a? Gem::Dependency
|
246
|
+
search = @search_for[dependency] ||= begin
|
247
|
+
index = index_for(dependency)
|
248
|
+
results = index.search(dependency, @base[dependency.name])
|
249
|
+
if vertex = @base_dg.vertex_named(dependency.name)
|
250
|
+
locked_requirement = vertex.payload.requirement
|
251
|
+
end
|
252
|
+
if results.any?
|
253
|
+
nested = []
|
254
|
+
results.each do |spec|
|
255
|
+
version, specs = nested.last
|
256
|
+
if version == spec.version
|
257
|
+
specs << spec
|
258
|
+
else
|
259
|
+
nested << [spec.version, [spec]]
|
260
|
+
end
|
261
|
+
end
|
262
|
+
nested.reduce([]) do |groups, (version, specs)|
|
263
|
+
next groups if locked_requirement && !locked_requirement.satisfied_by?(version)
|
264
|
+
groups << SpecGroup.new(specs)
|
265
|
+
end
|
266
|
+
else
|
267
|
+
[]
|
268
|
+
end
|
269
|
+
end
|
270
|
+
search.select {|sg| sg.for?(platform, @ruby_version) }.each {|sg| sg.activate_platform!(platform) }
|
271
|
+
end
|
272
|
+
|
273
|
+
def index_for(dependency)
|
274
|
+
@source_requirements[dependency.name] || @index
|
275
|
+
end
|
276
|
+
|
277
|
+
def name_for(dependency)
|
278
|
+
dependency.name
|
279
|
+
end
|
280
|
+
|
281
|
+
def name_for_explicit_dependency_source
|
282
|
+
Bundler.default_gemfile.basename.to_s
|
283
|
+
rescue
|
284
|
+
"Gemfile"
|
285
|
+
end
|
286
|
+
|
287
|
+
def name_for_locking_dependency_source
|
288
|
+
Bundler.default_lockfile.basename.to_s
|
289
|
+
rescue
|
290
|
+
"Gemfile.lock"
|
291
|
+
end
|
292
|
+
|
293
|
+
def requirement_satisfied_by?(requirement, activated, spec)
|
294
|
+
requirement.matches_spec?(spec) || spec.source.is_a?(Source::Gemspec)
|
295
|
+
end
|
296
|
+
|
297
|
+
def sort_dependencies(dependencies, activated, conflicts)
|
298
|
+
dependencies.sort_by do |dependency|
|
299
|
+
name = name_for(dependency)
|
300
|
+
[
|
301
|
+
activated.vertex_named(name).payload ? 0 : 1,
|
302
|
+
amount_constrained(dependency),
|
303
|
+
conflicts[name] ? 0 : 1,
|
304
|
+
activated.vertex_named(name).payload ? 0 : search_for(dependency).count,
|
305
|
+
]
|
306
|
+
end
|
307
|
+
end
|
308
|
+
|
309
|
+
private
|
310
|
+
|
311
|
+
def amount_constrained(dependency)
|
312
|
+
@amount_constrained ||= {}
|
313
|
+
@amount_constrained[dependency.name] ||= begin
|
314
|
+
if (base = @base[dependency.name]) && !base.empty?
|
315
|
+
dependency.requirement.satisfied_by?(base.first.version) ? 0 : 1
|
316
|
+
else
|
317
|
+
all = index_for(dependency).search(dependency.name).size
|
318
|
+
if all <= 1
|
319
|
+
all
|
320
|
+
else
|
321
|
+
search = search_for(dependency).size
|
322
|
+
search - all
|
323
|
+
end
|
324
|
+
end
|
325
|
+
end
|
326
|
+
end
|
327
|
+
|
328
|
+
def verify_gemfile_dependencies_are_found!(requirements)
|
329
|
+
requirements.each do |requirement|
|
330
|
+
next if requirement.name == "bundler"
|
331
|
+
next unless search_for(requirement).empty?
|
332
|
+
if (base = @base[requirement.name]) && !base.empty?
|
333
|
+
version = base.first.version
|
334
|
+
message = "You have requested:\n" \
|
335
|
+
" #{requirement.name} #{requirement.requirement}\n\n" \
|
336
|
+
"The bundle currently has #{requirement.name} locked at #{version}.\n" \
|
337
|
+
"Try running `bundle update #{requirement.name}`\n\n" \
|
338
|
+
"If you are updating multiple gems in your Gemfile at once,\n" \
|
339
|
+
"try passing them all to `bundle update`"
|
340
|
+
elsif requirement.source
|
341
|
+
name = requirement.name
|
342
|
+
specs = @source_requirements[name][name]
|
343
|
+
versions_with_platforms = specs.map {|s| [s.version, s.platform] }
|
344
|
+
message = String.new("Could not find gem '#{requirement}' in #{requirement.source}.\n")
|
345
|
+
message << if versions_with_platforms.any?
|
346
|
+
"Source contains '#{name}' at: #{formatted_versions_with_platforms(versions_with_platforms)}"
|
347
|
+
else
|
348
|
+
"Source does not contain any versions of '#{requirement}'"
|
349
|
+
end
|
350
|
+
else
|
351
|
+
message = "Could not find gem '#{requirement}' in any of the gem sources " \
|
352
|
+
"listed in your Gemfile or available on this machine."
|
353
|
+
end
|
354
|
+
raise GemNotFound, message
|
355
|
+
end
|
356
|
+
end
|
357
|
+
|
358
|
+
def formatted_versions_with_platforms(versions_with_platforms)
|
359
|
+
version_platform_strs = versions_with_platforms.map do |vwp|
|
360
|
+
version = vwp.first
|
361
|
+
platform = vwp.last
|
362
|
+
version_platform_str = String.new(version.to_s)
|
363
|
+
version_platform_str << " #{platform}" unless platform.nil?
|
364
|
+
end
|
365
|
+
version_platform_strs.join(", ")
|
366
|
+
end
|
367
|
+
end
|
368
|
+
end
|