bundler 1.17.0.pre.2 → 2.1.0.pre.2
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of bundler might be problematic. Click here for more details.
- checksums.yaml +4 -4
- data/CHANGELOG.md +769 -570
- data/LICENSE.md +18 -19
- data/README.md +9 -8
- data/bundler.gemspec +12 -23
- data/exe/bundle +19 -3
- data/lib/bundler.rb +121 -68
- data/lib/bundler/build_metadata.rb +14 -7
- data/lib/bundler/capistrano.rb +4 -4
- data/lib/bundler/cli.rb +129 -121
- data/lib/bundler/cli/add.rb +27 -16
- data/lib/bundler/cli/common.rb +11 -12
- data/lib/bundler/cli/config.rb +161 -86
- data/lib/bundler/cli/console.rb +1 -1
- data/lib/bundler/cli/doctor.rb +4 -4
- data/lib/bundler/cli/exec.rb +4 -9
- data/lib/bundler/cli/gem.rb +5 -5
- data/lib/bundler/cli/info.rb +17 -5
- data/lib/bundler/cli/init.rb +1 -1
- data/lib/bundler/cli/install.rb +11 -10
- data/lib/bundler/cli/issue.rb +3 -3
- data/lib/bundler/cli/open.rb +10 -6
- data/lib/bundler/cli/outdated.rb +85 -81
- data/lib/bundler/cli/package.rb +8 -9
- data/lib/bundler/cli/plugin.rb +9 -2
- data/lib/bundler/cli/pristine.rb +1 -1
- data/lib/bundler/cli/show.rb +1 -1
- data/lib/bundler/cli/update.rb +31 -11
- data/lib/bundler/compact_index_client.rb +25 -9
- data/lib/bundler/compact_index_client/updater.rb +2 -6
- data/lib/bundler/current_ruby.rb +9 -7
- data/lib/bundler/definition.rb +35 -26
- data/lib/bundler/dependency.rb +16 -4
- data/lib/bundler/deployment.rb +1 -1
- data/lib/bundler/dsl.rb +15 -39
- data/lib/bundler/env.rb +8 -13
- data/lib/bundler/environment_preserver.rb +0 -1
- data/lib/bundler/feature_flag.rb +23 -32
- data/lib/bundler/fetcher.rb +14 -11
- data/lib/bundler/fetcher/compact_index.rb +26 -12
- data/lib/bundler/fetcher/dependency.rb +1 -1
- data/lib/bundler/fetcher/downloader.rb +4 -1
- data/lib/bundler/fetcher/index.rb +4 -2
- data/lib/bundler/friendly_errors.rb +4 -5
- data/lib/bundler/gem_helper.rb +39 -24
- data/lib/bundler/gem_helpers.rb +2 -4
- data/lib/bundler/gem_tasks.rb +1 -1
- data/lib/bundler/gem_version_promoter.rb +3 -3
- data/lib/bundler/graph.rb +2 -2
- data/lib/bundler/injector.rb +10 -8
- data/lib/bundler/inline.rb +19 -18
- data/lib/bundler/installer.rb +7 -14
- data/lib/bundler/installer/gem_installer.rb +5 -1
- data/lib/bundler/installer/parallel_installer.rb +4 -8
- data/lib/bundler/installer/standalone.rb +1 -2
- data/lib/bundler/lazy_specification.rb +2 -2
- data/lib/bundler/lockfile_parser.rb +13 -21
- data/lib/bundler/match_platform.rb +1 -1
- data/lib/bundler/plugin.rb +42 -29
- data/lib/bundler/plugin/api.rb +1 -1
- data/lib/bundler/plugin/api/source.rb +2 -2
- data/lib/bundler/plugin/index.rb +14 -3
- data/lib/bundler/plugin/installer.rb +28 -15
- data/lib/bundler/psyched_yaml.rb +1 -1
- data/lib/bundler/resolver.rb +72 -24
- data/lib/bundler/resolver/spec_group.rb +3 -2
- data/lib/bundler/retry.rb +2 -2
- data/lib/bundler/ruby_version.rb +4 -19
- data/lib/bundler/rubygems_ext.rb +10 -66
- data/lib/bundler/rubygems_gem_installer.rb +1 -1
- data/lib/bundler/rubygems_integration.rb +144 -395
- data/lib/bundler/runtime.rb +2 -9
- data/lib/bundler/settings.rb +15 -47
- data/lib/bundler/setup.rb +6 -5
- data/lib/bundler/shared_helpers.rb +64 -67
- data/lib/bundler/similarity_detector.rb +2 -2
- data/lib/bundler/source.rb +5 -5
- data/lib/bundler/source/git.rb +19 -12
- data/lib/bundler/source/git/git_proxy.rb +35 -39
- data/lib/bundler/source/metadata.rb +9 -5
- data/lib/bundler/source/path.rb +13 -8
- data/lib/bundler/source/rubygems.rb +11 -5
- data/lib/bundler/source/rubygems/remote.rb +1 -2
- data/lib/bundler/source_list.rb +9 -12
- data/lib/bundler/spec_set.rb +23 -12
- data/lib/bundler/stub_specification.rb +18 -30
- data/lib/bundler/templates/Executable.bundler +23 -14
- data/lib/bundler/templates/newgem/CODE_OF_CONDUCT.md.tt +3 -3
- data/lib/bundler/templates/newgem/Gemfile.tt +8 -2
- data/lib/bundler/templates/newgem/README.md.tt +4 -3
- data/lib/bundler/templates/newgem/newgem.gemspec.tt +6 -27
- data/lib/bundler/templates/newgem/test/test_helper.rb.tt +1 -1
- data/lib/bundler/templates/newgem/travis.yml.tt +0 -1
- data/lib/bundler/ui.rb +3 -3
- data/lib/bundler/ui/rg_proxy.rb +1 -1
- data/lib/bundler/ui/shell.rb +4 -8
- data/lib/bundler/vendor/connection_pool/lib/connection_pool.rb +161 -0
- data/lib/bundler/vendor/connection_pool/lib/connection_pool/monotonic_time.rb +66 -0
- data/lib/bundler/vendor/connection_pool/lib/connection_pool/timed_stack.rb +176 -0
- data/lib/bundler/vendor/connection_pool/lib/connection_pool/version.rb +3 -0
- data/lib/bundler/vendor/fileutils/lib/fileutils.rb +151 -48
- data/lib/bundler/vendor/fileutils/lib/fileutils/version.rb +5 -0
- data/lib/bundler/vendor/molinillo/lib/molinillo.rb +6 -6
- data/lib/bundler/vendor/molinillo/lib/molinillo/dependency_graph.rb +2 -2
- data/lib/bundler/vendor/molinillo/lib/molinillo/dependency_graph/add_edge_no_circular.rb +1 -1
- data/lib/bundler/vendor/molinillo/lib/molinillo/dependency_graph/add_vertex.rb +1 -1
- data/lib/bundler/vendor/molinillo/lib/molinillo/dependency_graph/delete_edge.rb +1 -1
- data/lib/bundler/vendor/molinillo/lib/molinillo/dependency_graph/detach_vertex_named.rb +1 -1
- data/lib/bundler/vendor/molinillo/lib/molinillo/dependency_graph/log.rb +6 -6
- data/lib/bundler/vendor/molinillo/lib/molinillo/dependency_graph/set_payload.rb +1 -1
- data/lib/bundler/vendor/molinillo/lib/molinillo/dependency_graph/tag.rb +1 -1
- data/lib/bundler/vendor/molinillo/lib/molinillo/dependency_graph/vertex.rb +30 -8
- data/lib/bundler/vendor/molinillo/lib/molinillo/errors.rb +1 -1
- data/lib/bundler/vendor/molinillo/lib/molinillo/resolution.rb +4 -4
- data/lib/bundler/vendor/molinillo/lib/molinillo/resolver.rb +2 -2
- data/lib/bundler/vendor/net-http-persistent/lib/net/http/persistent.rb +248 -279
- data/lib/bundler/vendor/net-http-persistent/lib/net/http/persistent/connection.rb +40 -0
- data/lib/bundler/vendor/net-http-persistent/lib/net/http/persistent/pool.rb +53 -0
- data/lib/bundler/vendor/net-http-persistent/lib/net/http/persistent/timed_stack_multi.rb +79 -0
- data/lib/bundler/vendor/thor/lib/thor.rb +7 -2
- data/lib/bundler/vendor/thor/lib/thor/actions.rb +21 -11
- data/lib/bundler/vendor/thor/lib/thor/actions/create_file.rb +1 -1
- data/lib/bundler/vendor/thor/lib/thor/actions/create_link.rb +1 -1
- data/lib/bundler/vendor/thor/lib/thor/actions/directory.rb +1 -1
- data/lib/bundler/vendor/thor/lib/thor/actions/file_manipulation.rb +11 -2
- data/lib/bundler/vendor/thor/lib/thor/actions/inject_into_file.rb +1 -1
- data/lib/bundler/vendor/thor/lib/thor/base.rb +16 -17
- data/lib/bundler/vendor/thor/lib/thor/error.rb +82 -0
- data/lib/bundler/vendor/thor/lib/thor/group.rb +3 -3
- data/lib/bundler/vendor/thor/lib/thor/line_editor.rb +2 -2
- data/lib/bundler/vendor/thor/lib/thor/parser.rb +4 -4
- data/lib/bundler/vendor/thor/lib/thor/parser/options.rb +7 -2
- data/lib/bundler/vendor/thor/lib/thor/runner.rb +6 -6
- data/lib/bundler/vendor/thor/lib/thor/shell.rb +4 -4
- data/lib/bundler/vendor/thor/lib/thor/shell/basic.rb +52 -7
- data/lib/bundler/vendor/thor/lib/thor/shell/color.rb +1 -1
- data/lib/bundler/vendor/thor/lib/thor/shell/html.rb +1 -1
- data/lib/bundler/vendor/thor/lib/thor/util.rb +1 -1
- data/lib/bundler/vendor/thor/lib/thor/version.rb +1 -1
- data/lib/bundler/vendored_fileutils.rb +1 -6
- data/lib/bundler/vendored_molinillo.rb +1 -1
- data/lib/bundler/vendored_persistent.rb +7 -5
- data/lib/bundler/vendored_thor.rb +2 -2
- data/lib/bundler/version.rb +1 -20
- data/lib/bundler/version_ranges.rb +51 -5
- data/lib/bundler/vlad.rb +2 -2
- data/lib/bundler/worker.rb +1 -3
- data/lib/bundler/yaml_serializer.rb +2 -3
- data/man/bundle-add.1 +10 -2
- data/man/bundle-add.1.txt +11 -5
- data/man/bundle-add.ronn +7 -1
- data/man/bundle-binstubs.1 +2 -2
- data/man/bundle-binstubs.1.txt +2 -2
- data/man/bundle-binstubs.ronn +1 -1
- data/man/bundle-check.1 +1 -1
- data/man/bundle-check.1.txt +6 -6
- data/man/bundle-clean.1 +1 -1
- data/man/bundle-clean.1.txt +1 -1
- data/man/bundle-config.1 +52 -36
- data/man/bundle-config.1.txt +82 -67
- data/man/bundle-config.ronn +56 -40
- data/man/bundle-doctor.1 +1 -1
- data/man/bundle-doctor.1.txt +1 -1
- data/man/bundle-exec.1 +2 -2
- data/man/bundle-exec.1.txt +2 -2
- data/man/bundle-exec.ronn +1 -1
- data/man/bundle-gem.1 +1 -1
- data/man/bundle-gem.1.txt +3 -3
- data/man/bundle-info.1 +1 -1
- data/man/bundle-info.1.txt +1 -1
- data/man/bundle-init.1 +2 -2
- data/man/bundle-init.1.txt +2 -2
- data/man/bundle-init.ronn +1 -1
- data/man/bundle-inject.1 +1 -1
- data/man/bundle-inject.1.txt +1 -1
- data/man/bundle-install.1 +8 -5
- data/man/bundle-install.1.txt +56 -51
- data/man/bundle-install.ronn +9 -4
- data/man/bundle-list.1 +1 -1
- data/man/bundle-list.1.txt +1 -1
- data/man/bundle-lock.1 +1 -1
- data/man/bundle-lock.1.txt +16 -16
- data/man/bundle-open.1 +1 -1
- data/man/bundle-open.1.txt +1 -1
- data/man/bundle-outdated.1 +1 -1
- data/man/bundle-outdated.1.txt +1 -1
- data/man/bundle-package.1 +1 -1
- data/man/bundle-package.1.txt +1 -1
- data/man/bundle-platform.1 +1 -1
- data/man/bundle-platform.1.txt +1 -1
- data/man/bundle-pristine.1 +1 -1
- data/man/bundle-pristine.1.txt +1 -1
- data/man/bundle-remove.1 +1 -1
- data/man/bundle-remove.1.txt +1 -1
- data/man/bundle-show.1 +1 -1
- data/man/bundle-show.1.txt +1 -1
- data/man/bundle-update.1 +4 -4
- data/man/bundle-update.1.txt +64 -65
- data/man/bundle-update.ronn +3 -3
- data/man/bundle-viz.1 +1 -1
- data/man/bundle-viz.1.txt +1 -1
- data/man/bundle.1 +7 -3
- data/man/bundle.1.txt +11 -8
- data/man/bundle.ronn +5 -2
- data/man/gemfile.5 +17 -20
- data/man/gemfile.5.ronn +14 -18
- data/man/gemfile.5.txt +108 -112
- metadata +17 -104
- data/exe/bundle_ruby +0 -60
- data/lib/bundler/cli/cache.rb +0 -36
- data/lib/bundler/compatibility_guard.rb +0 -14
- data/lib/bundler/ssl_certs/.document +0 -1
- data/lib/bundler/ssl_certs/certificate_manager.rb +0 -66
- data/lib/bundler/ssl_certs/index.rubygems.org/GlobalSignRootCA.pem +0 -21
- data/lib/bundler/ssl_certs/rubygems.global.ssl.fastly.net/DigiCertHighAssuranceEVRootCA.pem +0 -23
- data/lib/bundler/ssl_certs/rubygems.org/AddTrustExternalCARoot.pem +0 -25
- data/lib/bundler/vendor/net-http-persistent/lib/net/http/faster.rb +0 -27
- data/lib/bundler/vendor/net-http-persistent/lib/net/http/persistent/ssl_reuse.rb +0 -129
@@ -1,27 +0,0 @@
|
|
1
|
-
require 'net/protocol'
|
2
|
-
|
3
|
-
##
|
4
|
-
# Aaron Patterson's monkeypatch (accepted into 1.9.1) to fix Net::HTTP's speed
|
5
|
-
# problems.
|
6
|
-
#
|
7
|
-
# http://gist.github.com/251244
|
8
|
-
|
9
|
-
class Net::BufferedIO #:nodoc:
|
10
|
-
alias :old_rbuf_fill :rbuf_fill
|
11
|
-
|
12
|
-
def rbuf_fill
|
13
|
-
if @io.respond_to? :read_nonblock then
|
14
|
-
begin
|
15
|
-
@rbuf << @io.read_nonblock(65536)
|
16
|
-
rescue Errno::EWOULDBLOCK, Errno::EAGAIN => e
|
17
|
-
retry if IO.select [@io], nil, nil, @read_timeout
|
18
|
-
raise Timeout::Error, e.message
|
19
|
-
end
|
20
|
-
else # SSL sockets do not have read_nonblock
|
21
|
-
timeout @read_timeout do
|
22
|
-
@rbuf << @io.sysread(65536)
|
23
|
-
end
|
24
|
-
end
|
25
|
-
end
|
26
|
-
end if RUBY_VERSION < '1.9'
|
27
|
-
|
@@ -1,129 +0,0 @@
|
|
1
|
-
##
|
2
|
-
# This Net::HTTP subclass adds SSL session reuse and Server Name Indication
|
3
|
-
# (SNI) RFC 3546.
|
4
|
-
#
|
5
|
-
# DO NOT DEPEND UPON THIS CLASS
|
6
|
-
#
|
7
|
-
# This class is an implementation detail and is subject to change or removal
|
8
|
-
# at any time.
|
9
|
-
|
10
|
-
class Bundler::Persistent::Net::HTTP::Persistent::SSLReuse < Net::HTTP
|
11
|
-
|
12
|
-
@is_proxy_class = false
|
13
|
-
@proxy_addr = nil
|
14
|
-
@proxy_port = nil
|
15
|
-
@proxy_user = nil
|
16
|
-
@proxy_pass = nil
|
17
|
-
|
18
|
-
def initialize address, port = nil # :nodoc:
|
19
|
-
super
|
20
|
-
|
21
|
-
@ssl_session = nil
|
22
|
-
end
|
23
|
-
|
24
|
-
##
|
25
|
-
# From ruby trunk r33086 including http://redmine.ruby-lang.org/issues/5341
|
26
|
-
|
27
|
-
def connect # :nodoc:
|
28
|
-
D "opening connection to #{conn_address()}..."
|
29
|
-
s = timeout(@open_timeout) { TCPSocket.open(conn_address(), conn_port()) }
|
30
|
-
D "opened"
|
31
|
-
if use_ssl?
|
32
|
-
ssl_parameters = Hash.new
|
33
|
-
iv_list = instance_variables
|
34
|
-
SSL_ATTRIBUTES.each do |name|
|
35
|
-
ivname = "@#{name}".intern
|
36
|
-
if iv_list.include?(ivname) and
|
37
|
-
value = instance_variable_get(ivname)
|
38
|
-
ssl_parameters[name] = value
|
39
|
-
end
|
40
|
-
end
|
41
|
-
unless @ssl_context then
|
42
|
-
@ssl_context = OpenSSL::SSL::SSLContext.new
|
43
|
-
@ssl_context.set_params(ssl_parameters)
|
44
|
-
end
|
45
|
-
s = OpenSSL::SSL::SSLSocket.new(s, @ssl_context)
|
46
|
-
s.sync_close = true
|
47
|
-
end
|
48
|
-
@socket = Net::BufferedIO.new(s)
|
49
|
-
@socket.read_timeout = @read_timeout
|
50
|
-
@socket.continue_timeout = @continue_timeout if
|
51
|
-
@socket.respond_to? :continue_timeout
|
52
|
-
@socket.debug_output = @debug_output
|
53
|
-
if use_ssl?
|
54
|
-
begin
|
55
|
-
if proxy?
|
56
|
-
@socket.writeline sprintf('CONNECT %s:%s HTTP/%s',
|
57
|
-
@address, @port, HTTPVersion)
|
58
|
-
@socket.writeline "Host: #{@address}:#{@port}"
|
59
|
-
if proxy_user
|
60
|
-
credential = ["#{proxy_user}:#{proxy_pass}"].pack('m')
|
61
|
-
credential.delete!("\r\n")
|
62
|
-
@socket.writeline "Proxy-Authorization: Basic #{credential}"
|
63
|
-
end
|
64
|
-
@socket.writeline ''
|
65
|
-
Net::HTTPResponse.read_new(@socket).value
|
66
|
-
end
|
67
|
-
s.session = @ssl_session if @ssl_session
|
68
|
-
# Server Name Indication (SNI) RFC 3546
|
69
|
-
s.hostname = @address if s.respond_to? :hostname=
|
70
|
-
timeout(@open_timeout) { s.connect }
|
71
|
-
if @ssl_context.verify_mode != OpenSSL::SSL::VERIFY_NONE
|
72
|
-
s.post_connection_check(@address)
|
73
|
-
end
|
74
|
-
@ssl_session = s.session
|
75
|
-
rescue => exception
|
76
|
-
D "Conn close because of connect error #{exception}"
|
77
|
-
@socket.close if @socket and not @socket.closed?
|
78
|
-
raise exception
|
79
|
-
end
|
80
|
-
end
|
81
|
-
on_connect
|
82
|
-
end if RUBY_VERSION > '1.9'
|
83
|
-
|
84
|
-
##
|
85
|
-
# From ruby_1_8_7 branch r29865 including a modified
|
86
|
-
# http://redmine.ruby-lang.org/issues/5341
|
87
|
-
|
88
|
-
def connect # :nodoc:
|
89
|
-
D "opening connection to #{conn_address()}..."
|
90
|
-
s = timeout(@open_timeout) { TCPSocket.open(conn_address(), conn_port()) }
|
91
|
-
D "opened"
|
92
|
-
if use_ssl?
|
93
|
-
unless @ssl_context.verify_mode
|
94
|
-
warn "warning: peer certificate won't be verified in this SSL session"
|
95
|
-
@ssl_context.verify_mode = OpenSSL::SSL::VERIFY_NONE
|
96
|
-
end
|
97
|
-
s = OpenSSL::SSL::SSLSocket.new(s, @ssl_context)
|
98
|
-
s.sync_close = true
|
99
|
-
end
|
100
|
-
@socket = Net::BufferedIO.new(s)
|
101
|
-
@socket.read_timeout = @read_timeout
|
102
|
-
@socket.debug_output = @debug_output
|
103
|
-
if use_ssl?
|
104
|
-
if proxy?
|
105
|
-
@socket.writeline sprintf('CONNECT %s:%s HTTP/%s',
|
106
|
-
@address, @port, HTTPVersion)
|
107
|
-
@socket.writeline "Host: #{@address}:#{@port}"
|
108
|
-
if proxy_user
|
109
|
-
credential = ["#{proxy_user}:#{proxy_pass}"].pack('m')
|
110
|
-
credential.delete!("\r\n")
|
111
|
-
@socket.writeline "Proxy-Authorization: Basic #{credential}"
|
112
|
-
end
|
113
|
-
@socket.writeline ''
|
114
|
-
Net::HTTPResponse.read_new(@socket).value
|
115
|
-
end
|
116
|
-
s.session = @ssl_session if @ssl_session
|
117
|
-
s.connect
|
118
|
-
if @ssl_context.verify_mode != OpenSSL::SSL::VERIFY_NONE
|
119
|
-
s.post_connection_check(@address)
|
120
|
-
end
|
121
|
-
@ssl_session = s.session
|
122
|
-
end
|
123
|
-
on_connect
|
124
|
-
end if RUBY_VERSION < '1.9'
|
125
|
-
|
126
|
-
private :connect
|
127
|
-
|
128
|
-
end
|
129
|
-
|