bundler 2.4.21 → 2.5.0
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 +74 -0
- data/README.md +1 -2
- data/bundler.gemspec +4 -2
- data/exe/bundle +1 -10
- data/lib/bundler/build_metadata.rb +3 -3
- data/lib/bundler/capistrano.rb +1 -1
- data/lib/bundler/checksum.rb +245 -0
- data/lib/bundler/ci_detector.rb +75 -0
- data/lib/bundler/cli/add.rb +3 -3
- data/lib/bundler/cli/binstubs.rb +4 -4
- data/lib/bundler/cli/cache.rb +1 -1
- data/lib/bundler/cli/check.rb +1 -1
- data/lib/bundler/cli/common.rb +9 -1
- data/lib/bundler/cli/config.rb +8 -7
- data/lib/bundler/cli/console.rb +3 -2
- data/lib/bundler/cli/doctor.rb +2 -2
- data/lib/bundler/cli/exec.rb +1 -1
- data/lib/bundler/cli/gem.rb +31 -23
- data/lib/bundler/cli/info.rb +2 -13
- data/lib/bundler/cli/install.rb +5 -4
- data/lib/bundler/cli/issue.rb +1 -1
- data/lib/bundler/cli/lock.rb +4 -4
- data/lib/bundler/cli/open.rb +1 -1
- data/lib/bundler/cli/outdated.rb +6 -6
- data/lib/bundler/cli/plugin.rb +7 -14
- data/lib/bundler/cli/pristine.rb +38 -30
- data/lib/bundler/cli/show.rb +2 -2
- data/lib/bundler/cli/update.rb +5 -5
- data/lib/bundler/cli.rb +215 -263
- data/lib/bundler/compact_index_client/cache.rb +29 -9
- data/lib/bundler/compact_index_client/cache_file.rb +153 -0
- data/lib/bundler/compact_index_client/gem_parser.rb +7 -3
- data/lib/bundler/compact_index_client/updater.rb +79 -81
- data/lib/bundler/compact_index_client.rb +14 -7
- data/lib/bundler/constants.rb +1 -1
- data/lib/bundler/current_ruby.rb +5 -21
- data/lib/bundler/definition.rb +43 -16
- data/lib/bundler/dependency.rb +16 -12
- data/lib/bundler/digest.rb +2 -2
- data/lib/bundler/dsl.rb +43 -25
- data/lib/bundler/endpoint_specification.rb +6 -2
- data/lib/bundler/env.rb +1 -3
- data/lib/bundler/errors.rb +58 -0
- data/lib/bundler/fetcher/base.rb +3 -1
- data/lib/bundler/fetcher/compact_index.rb +4 -4
- data/lib/bundler/fetcher/downloader.rb +13 -11
- data/lib/bundler/fetcher/gem_remote_fetcher.rb +16 -0
- data/lib/bundler/fetcher/index.rb +1 -1
- data/lib/bundler/fetcher.rb +28 -25
- data/lib/bundler/friendly_errors.rb +5 -5
- data/lib/bundler/gem_helper.rb +1 -1
- data/lib/bundler/gem_helpers.rb +12 -2
- data/lib/bundler/graph.rb +9 -9
- data/lib/bundler/index.rb +1 -2
- data/lib/bundler/injector.rb +1 -1
- data/lib/bundler/inline.rb +3 -3
- data/lib/bundler/installer/gem_installer.rb +10 -10
- data/lib/bundler/installer/parallel_installer.rb +16 -8
- data/lib/bundler/installer/standalone.rb +2 -3
- data/lib/bundler/installer.rb +9 -9
- data/lib/bundler/lazy_specification.rb +28 -17
- data/lib/bundler/lockfile_generator.rb +9 -0
- data/lib/bundler/lockfile_parser.rb +81 -10
- data/lib/bundler/man/bundle-add.1 +3 -26
- data/lib/bundler/man/bundle-binstubs.1 +4 -16
- data/lib/bundler/man/bundle-cache.1 +3 -24
- data/lib/bundler/man/bundle-check.1 +3 -12
- data/lib/bundler/man/bundle-clean.1 +3 -10
- data/lib/bundler/man/bundle-config.1 +20 -211
- data/lib/bundler/man/bundle-config.1.ronn +6 -0
- data/lib/bundler/man/bundle-console.1 +4 -22
- data/lib/bundler/man/bundle-doctor.1 +4 -18
- data/lib/bundler/man/bundle-exec.1 +12 -73
- data/lib/bundler/man/bundle-gem.1 +13 -49
- data/lib/bundler/man/bundle-help.1 +3 -7
- data/lib/bundler/man/bundle-info.1 +3 -9
- data/lib/bundler/man/bundle-init.1 +3 -12
- data/lib/bundler/man/bundle-inject.1 +6 -19
- data/lib/bundler/man/bundle-install.1 +27 -125
- data/lib/bundler/man/bundle-install.1.ronn +1 -0
- data/lib/bundler/man/bundle-list.1 +4 -19
- data/lib/bundler/man/bundle-lock.1 +5 -29
- data/lib/bundler/man/bundle-open.1 +7 -27
- data/lib/bundler/man/bundle-outdated.1 +3 -55
- data/lib/bundler/man/bundle-outdated.1.ronn +1 -0
- data/lib/bundler/man/bundle-platform.1 +5 -27
- data/lib/bundler/man/bundle-plugin.1 +3 -29
- data/lib/bundler/man/bundle-pristine.1 +5 -16
- data/lib/bundler/man/bundle-remove.1 +4 -14
- data/lib/bundler/man/bundle-show.1 +3 -10
- data/lib/bundler/man/bundle-update.1 +18 -137
- data/lib/bundler/man/bundle-version.1 +3 -16
- data/lib/bundler/man/bundle-viz.1 +4 -16
- data/lib/bundler/man/bundle.1 +5 -44
- data/lib/bundler/man/gemfile.5 +24 -301
- data/lib/bundler/man/gemfile.5.ronn +4 -0
- data/lib/bundler/match_metadata.rb +4 -0
- data/lib/bundler/match_platform.rb +1 -1
- data/lib/bundler/plugin/api/source.rb +3 -2
- data/lib/bundler/plugin/index.rb +8 -0
- data/lib/bundler/plugin/installer.rb +1 -1
- data/lib/bundler/plugin.rb +12 -5
- data/lib/bundler/resolver/base.rb +1 -1
- data/lib/bundler/resolver/incompatibility.rb +1 -1
- data/lib/bundler/resolver/spec_group.rb +1 -4
- data/lib/bundler/resolver.rb +16 -16
- data/lib/bundler/ruby_dsl.rb +20 -12
- data/lib/bundler/ruby_version.rb +1 -1
- data/lib/bundler/rubygems_ext.rb +27 -54
- data/lib/bundler/rubygems_gem_installer.rb +23 -58
- data/lib/bundler/rubygems_integration.rb +25 -94
- data/lib/bundler/runtime.rb +2 -2
- data/lib/bundler/self_manager.rb +23 -7
- data/lib/bundler/settings.rb +27 -7
- data/lib/bundler/setup.rb +4 -1
- data/lib/bundler/shared_helpers.rb +35 -13
- data/lib/bundler/source/git/git_proxy.rb +22 -14
- data/lib/bundler/source/git.rb +4 -3
- data/lib/bundler/source/metadata.rb +16 -16
- data/lib/bundler/source/path.rb +7 -6
- data/lib/bundler/source/rubygems.rb +21 -14
- data/lib/bundler/source.rb +2 -0
- data/lib/bundler/spec_set.rb +43 -12
- data/lib/bundler/stub_specification.rb +1 -0
- data/lib/bundler/templates/Executable.bundler +1 -1
- data/lib/bundler/templates/newgem/README.md.tt +3 -3
- data/lib/bundler/templates/newgem/Rakefile.tt +2 -6
- data/lib/bundler/templates/newgem/ext/newgem/Cargo.toml.tt +1 -1
- data/lib/bundler/templates/newgem/newgem.gemspec.tt +1 -1
- data/lib/bundler/templates/newgem/standard.yml.tt +1 -1
- data/lib/bundler/ui/shell.rb +2 -2
- data/lib/bundler/vendor/connection_pool/lib/connection_pool/version.rb +1 -1
- data/lib/bundler/vendor/connection_pool/lib/connection_pool.rb +53 -6
- data/lib/bundler/vendor/fileutils/lib/fileutils.rb +8 -20
- data/lib/bundler/vendor/net-http-persistent/lib/net/http/persistent/connection.rb +4 -3
- data/lib/bundler/vendor/net-http-persistent/lib/net/http/persistent/pool.rb +23 -11
- data/lib/bundler/vendor/net-http-persistent/lib/net/http/persistent/timed_stack_multi.rb +1 -1
- data/lib/bundler/vendor/net-http-persistent/lib/net/http/persistent.rb +36 -36
- data/lib/bundler/vendor/thor/lib/thor/actions/create_file.rb +3 -2
- data/lib/bundler/vendor/thor/lib/thor/actions/directory.rb +1 -1
- data/lib/bundler/vendor/thor/lib/thor/actions/empty_directory.rb +1 -1
- data/lib/bundler/vendor/thor/lib/thor/actions/file_manipulation.rb +8 -10
- data/lib/bundler/vendor/thor/lib/thor/actions/inject_into_file.rb +15 -4
- data/lib/bundler/vendor/thor/lib/thor/actions.rb +15 -15
- data/lib/bundler/vendor/thor/lib/thor/base.rb +140 -14
- data/lib/bundler/vendor/thor/lib/thor/command.rb +13 -4
- data/lib/bundler/vendor/thor/lib/thor/core_ext/hash_with_indifferent_access.rb +4 -0
- data/lib/bundler/vendor/thor/lib/thor/error.rb +16 -25
- data/lib/bundler/vendor/thor/lib/thor/group.rb +1 -1
- data/lib/bundler/vendor/thor/lib/thor/invocation.rb +1 -1
- data/lib/bundler/vendor/thor/lib/thor/nested_context.rb +2 -2
- data/lib/bundler/vendor/thor/lib/thor/parser/argument.rb +20 -1
- data/lib/bundler/vendor/thor/lib/thor/parser/arguments.rb +33 -17
- data/lib/bundler/vendor/thor/lib/thor/parser/option.rb +27 -8
- data/lib/bundler/vendor/thor/lib/thor/parser/options.rb +44 -6
- data/lib/bundler/vendor/thor/lib/thor/rake_compat.rb +2 -2
- data/lib/bundler/vendor/thor/lib/thor/runner.rb +40 -30
- data/lib/bundler/vendor/thor/lib/thor/shell/basic.rb +26 -150
- data/lib/bundler/vendor/thor/lib/thor/shell/color.rb +4 -46
- data/lib/bundler/vendor/thor/lib/thor/shell/column_printer.rb +29 -0
- data/lib/bundler/vendor/thor/lib/thor/shell/html.rb +3 -45
- data/lib/bundler/vendor/thor/lib/thor/shell/lcs_diff.rb +49 -0
- data/lib/bundler/vendor/thor/lib/thor/shell/table_printer.rb +134 -0
- data/lib/bundler/vendor/thor/lib/thor/shell/terminal.rb +42 -0
- data/lib/bundler/vendor/thor/lib/thor/shell/wrapped_printer.rb +38 -0
- data/lib/bundler/vendor/thor/lib/thor/shell.rb +1 -1
- data/lib/bundler/vendor/thor/lib/thor/util.rb +8 -7
- data/lib/bundler/vendor/thor/lib/thor/version.rb +1 -1
- data/lib/bundler/vendor/thor/lib/thor.rb +155 -8
- data/lib/bundler/vendor/tsort/lib/tsort.rb +3 -0
- data/lib/bundler/vendor/uri/lib/uri/common.rb +256 -132
- data/lib/bundler/vendor/uri/lib/uri/generic.rb +1 -0
- data/lib/bundler/vendor/uri/lib/uri/rfc3986_parser.rb +95 -31
- data/lib/bundler/vendor/uri/lib/uri/version.rb +1 -1
- data/lib/bundler/vendored_net_http.rb +8 -0
- data/lib/bundler/vendored_persistent.rb +0 -4
- data/lib/bundler/vendored_timeout.rb +8 -0
- data/lib/bundler/version.rb +1 -1
- data/lib/bundler/vlad.rb +1 -1
- data/lib/bundler/yaml_serializer.rb +9 -4
- data/lib/bundler.rb +38 -35
- metadata +16 -5
|
@@ -1,9 +1,73 @@
|
|
|
1
|
-
# frozen_string_literal:
|
|
1
|
+
# frozen_string_literal: true
|
|
2
2
|
module Bundler::URI
|
|
3
3
|
class RFC3986_Parser # :nodoc:
|
|
4
4
|
# Bundler::URI defined in RFC3986
|
|
5
|
-
|
|
6
|
-
|
|
5
|
+
HOST = %r[
|
|
6
|
+
(?<IP-literal>\[(?:
|
|
7
|
+
(?<IPv6address>
|
|
8
|
+
(?:\h{1,4}:){6}
|
|
9
|
+
(?<ls32>\h{1,4}:\h{1,4}
|
|
10
|
+
| (?<IPv4address>(?<dec-octet>[1-9]\d|1\d{2}|2[0-4]\d|25[0-5]|\d)
|
|
11
|
+
\.\g<dec-octet>\.\g<dec-octet>\.\g<dec-octet>)
|
|
12
|
+
)
|
|
13
|
+
| ::(?:\h{1,4}:){5}\g<ls32>
|
|
14
|
+
| \h{1,4}?::(?:\h{1,4}:){4}\g<ls32>
|
|
15
|
+
| (?:(?:\h{1,4}:)?\h{1,4})?::(?:\h{1,4}:){3}\g<ls32>
|
|
16
|
+
| (?:(?:\h{1,4}:){,2}\h{1,4})?::(?:\h{1,4}:){2}\g<ls32>
|
|
17
|
+
| (?:(?:\h{1,4}:){,3}\h{1,4})?::\h{1,4}:\g<ls32>
|
|
18
|
+
| (?:(?:\h{1,4}:){,4}\h{1,4})?::\g<ls32>
|
|
19
|
+
| (?:(?:\h{1,4}:){,5}\h{1,4})?::\h{1,4}
|
|
20
|
+
| (?:(?:\h{1,4}:){,6}\h{1,4})?::
|
|
21
|
+
)
|
|
22
|
+
| (?<IPvFuture>v\h++\.[!$&-.0-9:;=A-Z_a-z~]++)
|
|
23
|
+
)\])
|
|
24
|
+
| \g<IPv4address>
|
|
25
|
+
| (?<reg-name>(?:%\h\h|[!$&-.0-9;=A-Z_a-z~])*+)
|
|
26
|
+
]x
|
|
27
|
+
|
|
28
|
+
USERINFO = /(?:%\h\h|[!$&-.0-9:;=A-Z_a-z~])*+/
|
|
29
|
+
|
|
30
|
+
SCHEME = %r[[A-Za-z][+\-.0-9A-Za-z]*+].source
|
|
31
|
+
SEG = %r[(?:%\h\h|[!$&-.0-9:;=@A-Z_a-z~/])].source
|
|
32
|
+
SEG_NC = %r[(?:%\h\h|[!$&-.0-9;=@A-Z_a-z~])].source
|
|
33
|
+
FRAGMENT = %r[(?:%\h\h|[!$&-.0-9:;=@A-Z_a-z~/?])*+].source
|
|
34
|
+
|
|
35
|
+
RFC3986_URI = %r[\A
|
|
36
|
+
(?<seg>#{SEG}){0}
|
|
37
|
+
(?<Bundler::URI>
|
|
38
|
+
(?<scheme>#{SCHEME}):
|
|
39
|
+
(?<hier-part>//
|
|
40
|
+
(?<authority>
|
|
41
|
+
(?:(?<userinfo>#{USERINFO.source})@)?
|
|
42
|
+
(?<host>#{HOST.source.delete(" \n")})
|
|
43
|
+
(?::(?<port>\d*+))?
|
|
44
|
+
)
|
|
45
|
+
(?<path-abempty>(?:/\g<seg>*+)?)
|
|
46
|
+
| (?<path-absolute>/((?!/)\g<seg>++)?)
|
|
47
|
+
| (?<path-rootless>(?!/)\g<seg>++)
|
|
48
|
+
| (?<path-empty>)
|
|
49
|
+
)
|
|
50
|
+
(?:\?(?<query>[^\#]*+))?
|
|
51
|
+
(?:\#(?<fragment>#{FRAGMENT}))?
|
|
52
|
+
)\z]x
|
|
53
|
+
|
|
54
|
+
RFC3986_relative_ref = %r[\A
|
|
55
|
+
(?<seg>#{SEG}){0}
|
|
56
|
+
(?<relative-ref>
|
|
57
|
+
(?<relative-part>//
|
|
58
|
+
(?<authority>
|
|
59
|
+
(?:(?<userinfo>#{USERINFO.source})@)?
|
|
60
|
+
(?<host>#{HOST.source.delete(" \n")}(?<!/))?
|
|
61
|
+
(?::(?<port>\d*+))?
|
|
62
|
+
)
|
|
63
|
+
(?<path-abempty>(?:/\g<seg>*+)?)
|
|
64
|
+
| (?<path-absolute>/\g<seg>*+)
|
|
65
|
+
| (?<path-noscheme>#{SEG_NC}++(?:/\g<seg>*+)?)
|
|
66
|
+
| (?<path-empty>)
|
|
67
|
+
)
|
|
68
|
+
(?:\?(?<query>[^#]*+))?
|
|
69
|
+
(?:\#(?<fragment>#{FRAGMENT}))?
|
|
70
|
+
)\z]x
|
|
7
71
|
attr_reader :regexp
|
|
8
72
|
|
|
9
73
|
def initialize
|
|
@@ -19,9 +83,9 @@ module Bundler::URI
|
|
|
19
83
|
uri.ascii_only? or
|
|
20
84
|
raise InvalidURIError, "Bundler::URI must be ascii only #{uri.dump}"
|
|
21
85
|
if m = RFC3986_URI.match(uri)
|
|
22
|
-
query = m["query"
|
|
23
|
-
scheme = m["scheme"
|
|
24
|
-
opaque = m["path-rootless"
|
|
86
|
+
query = m["query"]
|
|
87
|
+
scheme = m["scheme"]
|
|
88
|
+
opaque = m["path-rootless"]
|
|
25
89
|
if opaque
|
|
26
90
|
opaque << "?#{query}" if query
|
|
27
91
|
[ scheme,
|
|
@@ -32,35 +96,35 @@ module Bundler::URI
|
|
|
32
96
|
nil, # path
|
|
33
97
|
opaque,
|
|
34
98
|
nil, # query
|
|
35
|
-
m["fragment"
|
|
99
|
+
m["fragment"]
|
|
36
100
|
]
|
|
37
101
|
else # normal
|
|
38
102
|
[ scheme,
|
|
39
|
-
m["userinfo"
|
|
40
|
-
m["host"
|
|
41
|
-
m["port"
|
|
103
|
+
m["userinfo"],
|
|
104
|
+
m["host"],
|
|
105
|
+
m["port"],
|
|
42
106
|
nil, # registry
|
|
43
|
-
(m["path-abempty"
|
|
44
|
-
m["path-absolute"
|
|
45
|
-
m["path-empty"
|
|
107
|
+
(m["path-abempty"] ||
|
|
108
|
+
m["path-absolute"] ||
|
|
109
|
+
m["path-empty"]),
|
|
46
110
|
nil, # opaque
|
|
47
111
|
query,
|
|
48
|
-
m["fragment"
|
|
112
|
+
m["fragment"]
|
|
49
113
|
]
|
|
50
114
|
end
|
|
51
115
|
elsif m = RFC3986_relative_ref.match(uri)
|
|
52
116
|
[ nil, # scheme
|
|
53
|
-
m["userinfo"
|
|
54
|
-
m["host"
|
|
55
|
-
m["port"
|
|
117
|
+
m["userinfo"],
|
|
118
|
+
m["host"],
|
|
119
|
+
m["port"],
|
|
56
120
|
nil, # registry,
|
|
57
|
-
(m["path-abempty"
|
|
58
|
-
m["path-absolute"
|
|
59
|
-
m["path-noscheme"
|
|
60
|
-
m["path-empty"
|
|
121
|
+
(m["path-abempty"] ||
|
|
122
|
+
m["path-absolute"] ||
|
|
123
|
+
m["path-noscheme"] ||
|
|
124
|
+
m["path-empty"]),
|
|
61
125
|
nil, # opaque
|
|
62
|
-
m["query"
|
|
63
|
-
m["fragment"
|
|
126
|
+
m["query"],
|
|
127
|
+
m["fragment"]
|
|
64
128
|
]
|
|
65
129
|
else
|
|
66
130
|
raise InvalidURIError, "bad Bundler::URI(is not Bundler::URI?): #{uri.inspect}"
|
|
@@ -92,14 +156,14 @@ module Bundler::URI
|
|
|
92
156
|
|
|
93
157
|
def default_regexp # :nodoc:
|
|
94
158
|
{
|
|
95
|
-
SCHEME:
|
|
96
|
-
USERINFO:
|
|
97
|
-
HOST:
|
|
98
|
-
ABS_PATH:
|
|
99
|
-
REL_PATH:
|
|
100
|
-
QUERY:
|
|
101
|
-
FRAGMENT:
|
|
102
|
-
OPAQUE:
|
|
159
|
+
SCHEME: %r[\A#{SCHEME}\z]o,
|
|
160
|
+
USERINFO: %r[\A#{USERINFO}\z]o,
|
|
161
|
+
HOST: %r[\A#{HOST}\z]o,
|
|
162
|
+
ABS_PATH: %r[\A/#{SEG}*+\z]o,
|
|
163
|
+
REL_PATH: %r[\A(?!/)#{SEG}++\z]o,
|
|
164
|
+
QUERY: %r[\A(?:%\h\h|[!$&-.0-9:;=@A-Z_a-z~/?])*+\z],
|
|
165
|
+
FRAGMENT: %r[\A#{FRAGMENT}\z]o,
|
|
166
|
+
OPAQUE: %r[\A(?:[^/].*)?\z],
|
|
103
167
|
PORT: /\A[\x09\x0a\x0c\x0d ]*+\d*[\x09\x0a\x0c\x0d ]*\z/,
|
|
104
168
|
}
|
|
105
169
|
end
|
data/lib/bundler/version.rb
CHANGED
data/lib/bundler/vlad.rb
CHANGED
|
@@ -13,5 +13,5 @@ require_relative "deployment"
|
|
|
13
13
|
include Rake::DSL if defined? Rake::DSL
|
|
14
14
|
|
|
15
15
|
namespace :vlad do
|
|
16
|
-
Bundler::Deployment.define_task(Rake::RemoteTask, :remote_task, :
|
|
16
|
+
Bundler::Deployment.define_task(Rake::RemoteTask, :remote_task, roles: :app)
|
|
17
17
|
end
|
|
@@ -17,7 +17,11 @@ module Bundler
|
|
|
17
17
|
if v.is_a?(Hash)
|
|
18
18
|
yaml << dump_hash(v).gsub(/^(?!$)/, " ") # indent all non-empty lines
|
|
19
19
|
elsif v.is_a?(Array) # Expected to be array of strings
|
|
20
|
-
|
|
20
|
+
if v.empty?
|
|
21
|
+
yaml << " []\n"
|
|
22
|
+
else
|
|
23
|
+
yaml << "\n- " << v.map {|s| s.to_s.gsub(/\s+/, " ").inspect }.join("\n- ") << "\n"
|
|
24
|
+
end
|
|
21
25
|
else
|
|
22
26
|
yaml << " " << v.to_s.gsub(/\s+/, " ").inspect << "\n"
|
|
23
27
|
end
|
|
@@ -32,7 +36,7 @@ module Bundler
|
|
|
32
36
|
(.*) # value
|
|
33
37
|
\1 # matching closing quote
|
|
34
38
|
$
|
|
35
|
-
/xo
|
|
39
|
+
/xo
|
|
36
40
|
|
|
37
41
|
HASH_REGEX = /
|
|
38
42
|
^
|
|
@@ -44,14 +48,14 @@ module Bundler
|
|
|
44
48
|
(.*) # value
|
|
45
49
|
\3 # matching closing quote
|
|
46
50
|
$
|
|
47
|
-
/xo
|
|
51
|
+
/xo
|
|
48
52
|
|
|
49
53
|
def load(str)
|
|
50
54
|
res = {}
|
|
51
55
|
stack = [res]
|
|
52
56
|
last_hash = nil
|
|
53
57
|
last_empty_key = nil
|
|
54
|
-
str.split(/\r?\n/)
|
|
58
|
+
str.split(/\r?\n/) do |line|
|
|
55
59
|
if match = HASH_REGEX.match(line)
|
|
56
60
|
indent, key, quote, val = match.captures
|
|
57
61
|
convert_to_backward_compatible_key!(key)
|
|
@@ -63,6 +67,7 @@ module Bundler
|
|
|
63
67
|
last_empty_key = key
|
|
64
68
|
last_hash = stack[depth]
|
|
65
69
|
else
|
|
70
|
+
val = [] if val == "[]" # empty array
|
|
66
71
|
stack[depth][key] = val
|
|
67
72
|
end
|
|
68
73
|
elsif match = ARRAY_REGEX.match(line)
|
data/lib/bundler.rb
CHANGED
|
@@ -17,7 +17,7 @@ require_relative "bundler/build_metadata"
|
|
|
17
17
|
# Bundler provides a consistent environment for Ruby projects by
|
|
18
18
|
# tracking and installing the exact gems and versions that are needed.
|
|
19
19
|
#
|
|
20
|
-
#
|
|
20
|
+
# Bundler is a part of Ruby's standard library.
|
|
21
21
|
#
|
|
22
22
|
# Bundler is used by creating _gemfiles_ listing all the project dependencies
|
|
23
23
|
# and (optionally) their versions and then using
|
|
@@ -39,6 +39,8 @@ module Bundler
|
|
|
39
39
|
environment_preserver.replace_with_backup
|
|
40
40
|
SUDO_MUTEX = Thread::Mutex.new
|
|
41
41
|
|
|
42
|
+
autoload :Checksum, File.expand_path("bundler/checksum", __dir__)
|
|
43
|
+
autoload :CIDetector, File.expand_path("bundler/ci_detector", __dir__)
|
|
42
44
|
autoload :Definition, File.expand_path("bundler/definition", __dir__)
|
|
43
45
|
autoload :Dependency, File.expand_path("bundler/dependency", __dir__)
|
|
44
46
|
autoload :Deprecate, File.expand_path("bundler/deprecate", __dir__)
|
|
@@ -192,7 +194,7 @@ module Bundler
|
|
|
192
194
|
end
|
|
193
195
|
|
|
194
196
|
def environment
|
|
195
|
-
SharedHelpers.major_deprecation 2, "Bundler.environment has been removed in favor of Bundler.load", :
|
|
197
|
+
SharedHelpers.major_deprecation 2, "Bundler.environment has been removed in favor of Bundler.load", print_caller_location: true
|
|
196
198
|
load
|
|
197
199
|
end
|
|
198
200
|
|
|
@@ -330,14 +332,6 @@ module Bundler
|
|
|
330
332
|
|
|
331
333
|
def rm_rf(path)
|
|
332
334
|
FileUtils.remove_entry_secure(path) if path && File.exist?(path)
|
|
333
|
-
rescue ArgumentError
|
|
334
|
-
message = <<EOF
|
|
335
|
-
It is a security vulnerability to allow your home directory to be world-writable, and bundler cannot continue.
|
|
336
|
-
You should probably consider fixing this issue by running `chmod o-w ~` on *nix.
|
|
337
|
-
Please refer to https://ruby-doc.org/stdlib-3.1.2/libdoc/fileutils/rdoc/FileUtils.html#method-c-remove_entry_secure for details.
|
|
338
|
-
EOF
|
|
339
|
-
File.world_writable?(path) ? Bundler.ui.warn(message) : raise
|
|
340
|
-
raise PathError, "Please fix the world-writable issue with your #{path} directory"
|
|
341
335
|
end
|
|
342
336
|
|
|
343
337
|
def settings
|
|
@@ -353,13 +347,13 @@ EOF
|
|
|
353
347
|
|
|
354
348
|
# @deprecated Use `unbundled_env` instead
|
|
355
349
|
def clean_env
|
|
356
|
-
|
|
357
|
-
2,
|
|
350
|
+
message =
|
|
358
351
|
"`Bundler.clean_env` has been deprecated in favor of `Bundler.unbundled_env`. " \
|
|
359
|
-
"If you instead want the environment before bundler was originally loaded, use `Bundler.original_env`"
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
352
|
+
"If you instead want the environment before bundler was originally loaded, use `Bundler.original_env`"
|
|
353
|
+
removed_message =
|
|
354
|
+
"`Bundler.clean_env` has been removed in favor of `Bundler.unbundled_env`. " \
|
|
355
|
+
"If you instead want the environment before bundler was originally loaded, use `Bundler.original_env`"
|
|
356
|
+
Bundler::SharedHelpers.major_deprecation(2, message, removed_message: removed_message, print_caller_location: true)
|
|
363
357
|
unbundled_env
|
|
364
358
|
end
|
|
365
359
|
|
|
@@ -396,13 +390,13 @@ EOF
|
|
|
396
390
|
|
|
397
391
|
# @deprecated Use `with_unbundled_env` instead
|
|
398
392
|
def with_clean_env
|
|
399
|
-
|
|
400
|
-
2,
|
|
393
|
+
message =
|
|
401
394
|
"`Bundler.with_clean_env` has been deprecated in favor of `Bundler.with_unbundled_env`. " \
|
|
402
|
-
"If you instead want the environment before bundler was originally loaded, use `Bundler.with_original_env`"
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
395
|
+
"If you instead want the environment before bundler was originally loaded, use `Bundler.with_original_env`"
|
|
396
|
+
removed_message =
|
|
397
|
+
"`Bundler.with_clean_env` has been removed in favor of `Bundler.with_unbundled_env`. " \
|
|
398
|
+
"If you instead want the environment before bundler was originally loaded, use `Bundler.with_original_env`"
|
|
399
|
+
Bundler::SharedHelpers.major_deprecation(2, message, removed_message: removed_message, print_caller_location: true)
|
|
406
400
|
with_env(unbundled_env) { yield }
|
|
407
401
|
end
|
|
408
402
|
|
|
@@ -418,13 +412,13 @@ EOF
|
|
|
418
412
|
|
|
419
413
|
# @deprecated Use `unbundled_system` instead
|
|
420
414
|
def clean_system(*args)
|
|
421
|
-
|
|
422
|
-
2,
|
|
415
|
+
message =
|
|
423
416
|
"`Bundler.clean_system` has been deprecated in favor of `Bundler.unbundled_system`. " \
|
|
424
|
-
"If you instead want to run the command in the environment before bundler was originally loaded, use `Bundler.original_system`"
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
417
|
+
"If you instead want to run the command in the environment before bundler was originally loaded, use `Bundler.original_system`"
|
|
418
|
+
removed_message =
|
|
419
|
+
"`Bundler.clean_system` has been removed in favor of `Bundler.unbundled_system`. " \
|
|
420
|
+
"If you instead want to run the command in the environment before bundler was originally loaded, use `Bundler.original_system`"
|
|
421
|
+
Bundler::SharedHelpers.major_deprecation(2, message, removed_message: removed_message, print_caller_location: true)
|
|
428
422
|
with_env(unbundled_env) { Kernel.system(*args) }
|
|
429
423
|
end
|
|
430
424
|
|
|
@@ -440,13 +434,13 @@ EOF
|
|
|
440
434
|
|
|
441
435
|
# @deprecated Use `unbundled_exec` instead
|
|
442
436
|
def clean_exec(*args)
|
|
443
|
-
|
|
444
|
-
2,
|
|
437
|
+
message =
|
|
445
438
|
"`Bundler.clean_exec` has been deprecated in favor of `Bundler.unbundled_exec`. " \
|
|
446
|
-
"If you instead want to exec to a command in the environment before bundler was originally loaded, use `Bundler.original_exec`"
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
439
|
+
"If you instead want to exec to a command in the environment before bundler was originally loaded, use `Bundler.original_exec`"
|
|
440
|
+
removed_message =
|
|
441
|
+
"`Bundler.clean_exec` has been removed in favor of `Bundler.unbundled_exec`. " \
|
|
442
|
+
"If you instead want to exec to a command in the environment before bundler was originally loaded, use `Bundler.original_exec`"
|
|
443
|
+
Bundler::SharedHelpers.major_deprecation(2, message, removed_message: removed_message, print_caller_location: true)
|
|
450
444
|
with_env(unbundled_env) { Kernel.exec(*args) }
|
|
451
445
|
end
|
|
452
446
|
|
|
@@ -515,7 +509,16 @@ EOF
|
|
|
515
509
|
end
|
|
516
510
|
|
|
517
511
|
def safe_load_marshal(data)
|
|
518
|
-
|
|
512
|
+
if Gem.respond_to?(:load_safe_marshal)
|
|
513
|
+
Gem.load_safe_marshal
|
|
514
|
+
begin
|
|
515
|
+
Gem::SafeMarshal.safe_load(data)
|
|
516
|
+
rescue Gem::SafeMarshal::Reader::Error, Gem::SafeMarshal::Visitors::ToRuby::Error => e
|
|
517
|
+
raise MarshalError, "#{e.class}: #{e.message}"
|
|
518
|
+
end
|
|
519
|
+
else
|
|
520
|
+
load_marshal(data, marshal_proc: SafeMarshal.proc)
|
|
521
|
+
end
|
|
519
522
|
end
|
|
520
523
|
|
|
521
524
|
def load_gemspec(file, validate = false)
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: bundler
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 2.
|
|
4
|
+
version: 2.5.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- André Arko
|
|
@@ -22,7 +22,7 @@ authors:
|
|
|
22
22
|
autorequire:
|
|
23
23
|
bindir: exe
|
|
24
24
|
cert_chain: []
|
|
25
|
-
date: 2023-
|
|
25
|
+
date: 2023-12-15 00:00:00.000000000 Z
|
|
26
26
|
dependencies: []
|
|
27
27
|
description: Bundler manages an application's dependencies through its entire life,
|
|
28
28
|
across many machines, systematically and repeatably
|
|
@@ -44,6 +44,8 @@ files:
|
|
|
44
44
|
- lib/bundler/.document
|
|
45
45
|
- lib/bundler/build_metadata.rb
|
|
46
46
|
- lib/bundler/capistrano.rb
|
|
47
|
+
- lib/bundler/checksum.rb
|
|
48
|
+
- lib/bundler/ci_detector.rb
|
|
47
49
|
- lib/bundler/cli.rb
|
|
48
50
|
- lib/bundler/cli/add.rb
|
|
49
51
|
- lib/bundler/cli/binstubs.rb
|
|
@@ -75,6 +77,7 @@ files:
|
|
|
75
77
|
- lib/bundler/cli/viz.rb
|
|
76
78
|
- lib/bundler/compact_index_client.rb
|
|
77
79
|
- lib/bundler/compact_index_client/cache.rb
|
|
80
|
+
- lib/bundler/compact_index_client/cache_file.rb
|
|
78
81
|
- lib/bundler/compact_index_client/gem_parser.rb
|
|
79
82
|
- lib/bundler/compact_index_client/updater.rb
|
|
80
83
|
- lib/bundler/constants.rb
|
|
@@ -95,6 +98,7 @@ files:
|
|
|
95
98
|
- lib/bundler/fetcher/compact_index.rb
|
|
96
99
|
- lib/bundler/fetcher/dependency.rb
|
|
97
100
|
- lib/bundler/fetcher/downloader.rb
|
|
101
|
+
- lib/bundler/fetcher/gem_remote_fetcher.rb
|
|
98
102
|
- lib/bundler/fetcher/index.rb
|
|
99
103
|
- lib/bundler/force_platform.rb
|
|
100
104
|
- lib/bundler/friendly_errors.rb
|
|
@@ -327,7 +331,12 @@ files:
|
|
|
327
331
|
- lib/bundler/vendor/thor/lib/thor/shell.rb
|
|
328
332
|
- lib/bundler/vendor/thor/lib/thor/shell/basic.rb
|
|
329
333
|
- lib/bundler/vendor/thor/lib/thor/shell/color.rb
|
|
334
|
+
- lib/bundler/vendor/thor/lib/thor/shell/column_printer.rb
|
|
330
335
|
- lib/bundler/vendor/thor/lib/thor/shell/html.rb
|
|
336
|
+
- lib/bundler/vendor/thor/lib/thor/shell/lcs_diff.rb
|
|
337
|
+
- lib/bundler/vendor/thor/lib/thor/shell/table_printer.rb
|
|
338
|
+
- lib/bundler/vendor/thor/lib/thor/shell/terminal.rb
|
|
339
|
+
- lib/bundler/vendor/thor/lib/thor/shell/wrapped_printer.rb
|
|
331
340
|
- lib/bundler/vendor/thor/lib/thor/util.rb
|
|
332
341
|
- lib/bundler/vendor/thor/lib/thor/version.rb
|
|
333
342
|
- lib/bundler/vendor/tsort/LICENSE.txt
|
|
@@ -349,9 +358,11 @@ files:
|
|
|
349
358
|
- lib/bundler/vendor/uri/lib/uri/ws.rb
|
|
350
359
|
- lib/bundler/vendor/uri/lib/uri/wss.rb
|
|
351
360
|
- lib/bundler/vendored_fileutils.rb
|
|
361
|
+
- lib/bundler/vendored_net_http.rb
|
|
352
362
|
- lib/bundler/vendored_persistent.rb
|
|
353
363
|
- lib/bundler/vendored_pub_grub.rb
|
|
354
364
|
- lib/bundler/vendored_thor.rb
|
|
365
|
+
- lib/bundler/vendored_timeout.rb
|
|
355
366
|
- lib/bundler/vendored_tsort.rb
|
|
356
367
|
- lib/bundler/vendored_uri.rb
|
|
357
368
|
- lib/bundler/version.rb
|
|
@@ -374,14 +385,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
|
374
385
|
requirements:
|
|
375
386
|
- - ">="
|
|
376
387
|
- !ruby/object:Gem::Version
|
|
377
|
-
version:
|
|
388
|
+
version: 3.0.0
|
|
378
389
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
379
390
|
requirements:
|
|
380
391
|
- - ">="
|
|
381
392
|
- !ruby/object:Gem::Version
|
|
382
|
-
version: 3.
|
|
393
|
+
version: 3.2.3
|
|
383
394
|
requirements: []
|
|
384
|
-
rubygems_version: 3.
|
|
395
|
+
rubygems_version: 3.5.0
|
|
385
396
|
signing_key:
|
|
386
397
|
specification_version: 4
|
|
387
398
|
summary: The best way to manage your application's dependencies
|