rubygems-update 3.3.23 → 3.3.25
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +16 -0
- data/Manifest.txt +0 -1
- data/bundler/CHANGELOG.md +23 -0
- data/bundler/lib/bundler/build_metadata.rb +2 -2
- data/bundler/lib/bundler/definition.rb +11 -29
- data/bundler/lib/bundler/endpoint_specification.rb +4 -0
- data/bundler/lib/bundler/gem_helpers.rb +0 -1
- data/bundler/lib/bundler/index.rb +0 -1
- data/bundler/lib/bundler/injector.rb +1 -1
- data/bundler/lib/bundler/lazy_specification.rb +8 -14
- data/bundler/lib/bundler/man/bundle-add.1 +1 -1
- data/bundler/lib/bundler/man/bundle-binstubs.1 +1 -1
- data/bundler/lib/bundler/man/bundle-cache.1 +1 -1
- data/bundler/lib/bundler/man/bundle-check.1 +1 -1
- data/bundler/lib/bundler/man/bundle-clean.1 +1 -1
- data/bundler/lib/bundler/man/bundle-config.1 +1 -1
- data/bundler/lib/bundler/man/bundle-console.1 +1 -1
- data/bundler/lib/bundler/man/bundle-doctor.1 +1 -1
- data/bundler/lib/bundler/man/bundle-exec.1 +1 -1
- data/bundler/lib/bundler/man/bundle-gem.1 +1 -1
- data/bundler/lib/bundler/man/bundle-help.1 +1 -1
- data/bundler/lib/bundler/man/bundle-info.1 +1 -1
- data/bundler/lib/bundler/man/bundle-init.1 +1 -1
- data/bundler/lib/bundler/man/bundle-inject.1 +1 -1
- data/bundler/lib/bundler/man/bundle-install.1 +1 -1
- data/bundler/lib/bundler/man/bundle-list.1 +1 -1
- data/bundler/lib/bundler/man/bundle-lock.1 +1 -1
- data/bundler/lib/bundler/man/bundle-open.1 +1 -1
- data/bundler/lib/bundler/man/bundle-outdated.1 +1 -1
- data/bundler/lib/bundler/man/bundle-platform.1 +1 -1
- data/bundler/lib/bundler/man/bundle-plugin.1 +1 -1
- data/bundler/lib/bundler/man/bundle-pristine.1 +1 -1
- data/bundler/lib/bundler/man/bundle-remove.1 +1 -1
- data/bundler/lib/bundler/man/bundle-show.1 +1 -1
- data/bundler/lib/bundler/man/bundle-update.1 +1 -1
- data/bundler/lib/bundler/man/bundle-version.1 +1 -1
- data/bundler/lib/bundler/man/bundle-viz.1 +1 -1
- data/bundler/lib/bundler/man/bundle.1 +1 -1
- data/bundler/lib/bundler/man/gemfile.5 +23 -12
- data/bundler/lib/bundler/man/gemfile.5.ronn +23 -13
- data/bundler/lib/bundler/remote_specification.rb +6 -2
- data/bundler/lib/bundler/resolver/base.rb +1 -1
- data/bundler/lib/bundler/resolver/spec_group.rb +22 -44
- data/bundler/lib/bundler/resolver.rb +24 -65
- data/bundler/lib/bundler/shared_helpers.rb +1 -2
- data/bundler/lib/bundler/version.rb +1 -1
- data/bundler/lib/bundler.rb +0 -1
- data/lib/rubygems/core_ext/kernel_warn.rb +1 -1
- data/lib/rubygems/request_set/gem_dependency_api.rb +1 -1
- data/lib/rubygems.rb +1 -1
- data/rubygems-update.gemspec +1 -1
- data/test/rubygems/alternate_cert.pem +14 -14
- data/test/rubygems/alternate_cert_32.pem +15 -15
- data/test/rubygems/alternate_key.pem +25 -25
- data/test/rubygems/child_cert.pem +15 -16
- data/test/rubygems/child_cert_32.pem +15 -16
- data/test/rubygems/child_key.pem +25 -25
- data/test/rubygems/encrypted_private_key.pem +26 -26
- data/test/rubygems/expired_cert.pem +15 -15
- data/test/rubygems/future_cert.pem +15 -15
- data/test/rubygems/future_cert_32.pem +15 -15
- data/test/rubygems/grandchild_cert.pem +15 -16
- data/test/rubygems/grandchild_cert_32.pem +15 -16
- data/test/rubygems/grandchild_key.pem +25 -25
- data/test/rubygems/invalid_issuer_cert.pem +16 -16
- data/test/rubygems/invalid_issuer_cert_32.pem +16 -16
- data/test/rubygems/invalid_key.pem +25 -25
- data/test/rubygems/invalid_signer_cert.pem +15 -15
- data/test/rubygems/invalid_signer_cert_32.pem +15 -15
- data/test/rubygems/invalidchild_cert.pem +15 -16
- data/test/rubygems/invalidchild_cert_32.pem +15 -16
- data/test/rubygems/invalidchild_key.pem +25 -25
- data/test/rubygems/private_key.pem +25 -25
- data/test/rubygems/public_cert.pem +16 -16
- data/test/rubygems/public_cert_32.pem +15 -15
- data/test/rubygems/public_key.pem +7 -7
- data/test/rubygems/test_gem_ext_cargo_builder/custom_name/Cargo.lock +6 -6
- data/test/rubygems/test_gem_ext_cargo_builder/custom_name/Cargo.toml +1 -1
- data/test/rubygems/test_gem_ext_cargo_builder/rust_ruby_example/Cargo.lock +6 -6
- data/test/rubygems/test_gem_ext_cargo_builder/rust_ruby_example/Cargo.toml +1 -1
- data/test/rubygems/test_gem_request_set_gem_dependency_api.rb +2 -2
- data/test/rubygems/test_gem_security.rb +5 -5
- data/test/rubygems/test_gem_security_signer.rb +6 -6
- data/test/rubygems/test_gem_source_git.rb +5 -0
- data/test/rubygems/wrong_key_cert.pem +15 -15
- data/test/rubygems/wrong_key_cert_32.pem +15 -15
- metadata +3 -4
- data/bundler/lib/bundler/dep_proxy.rb +0 -55
@@ -1,7 +1,7 @@
|
|
1
1
|
.\" generated with Ronn/v0.7.3
|
2
2
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
3
3
|
.
|
4
|
-
.TH "GEMFILE" "5" "
|
4
|
+
.TH "GEMFILE" "5" "October 2022" "" ""
|
5
5
|
.
|
6
6
|
.SH "NAME"
|
7
7
|
\fBGemfile\fR \- A format for describing gem dependencies for Ruby programs
|
@@ -73,13 +73,13 @@ Credentials in the source URL will take precedence over credentials set using \f
|
|
73
73
|
If your application requires a specific Ruby version or engine, specify your requirements using the \fBruby\fR method, with the following arguments\. All parameters are \fBOPTIONAL\fR unless otherwise specified\.
|
74
74
|
.
|
75
75
|
.SS "VERSION (required)"
|
76
|
-
The version of Ruby that your application requires\. If your application requires an alternate Ruby engine, such as JRuby,
|
76
|
+
The version of Ruby that your application requires\. If your application requires an alternate Ruby engine, such as JRuby, TruffleRuby, etc\., this should be the Ruby version that the engine is compatible with\.
|
77
77
|
.
|
78
78
|
.IP "" 4
|
79
79
|
.
|
80
80
|
.nf
|
81
81
|
|
82
|
-
ruby "1\.
|
82
|
+
ruby "3\.1\.2"
|
83
83
|
.
|
84
84
|
.fi
|
85
85
|
.
|
@@ -95,7 +95,7 @@ What exactly is an Engine? \- A Ruby engine is an implementation of the Ruby lan
|
|
95
95
|
For background: the reference or original implementation of the Ruby programming language is called Matz\'s Ruby Interpreter \fIhttps://en\.wikipedia\.org/wiki/Ruby_MRI\fR, or MRI for short\. This is named after Ruby creator Yukihiro Matsumoto, also known as Matz\. MRI is also known as CRuby, because it is written in C\. MRI is the most widely used Ruby engine\.
|
96
96
|
.
|
97
97
|
.IP "\(bu" 4
|
98
|
-
Other implementations \fIhttps://www\.ruby\-lang\.org/en/about/\fR of Ruby exist\. Some of the more well\-known implementations include
|
98
|
+
Other implementations \fIhttps://www\.ruby\-lang\.org/en/about/\fR of Ruby exist\. Some of the more well\-known implementations include JRuby \fIhttp://jruby\.org/\fR and TruffleRuby \fIhttps://www\.graalvm\.org/ruby/\fR\. Rubinius is an alternative implementation of Ruby written in Ruby\. JRuby is an implementation of Ruby on the JVM, short for Java Virtual Machine\. TruffleRuby is a Ruby implementation on the GraalVM, a language toolkit built on the JVM\.
|
99
99
|
.
|
100
100
|
.IP "" 0
|
101
101
|
.
|
@@ -106,20 +106,23 @@ Each application \fImay\fR specify a Ruby engine version\. If an engine version
|
|
106
106
|
.
|
107
107
|
.nf
|
108
108
|
|
109
|
-
ruby "
|
109
|
+
ruby "2\.6\.8", engine: "jruby", engine_version: "9\.3\.8\.0"
|
110
110
|
.
|
111
111
|
.fi
|
112
112
|
.
|
113
113
|
.IP "" 0
|
114
114
|
.
|
115
115
|
.SS "PATCHLEVEL"
|
116
|
-
Each application \fImay\fR specify a Ruby patchlevel\.
|
116
|
+
Each application \fImay\fR specify a Ruby patchlevel\. Specifying the patchlevel has been meaningless since Ruby 2\.1\.0 was released as the patchlevel is now uniquely determined by a combination of major, minor, and teeny version numbers\.
|
117
|
+
.
|
118
|
+
.P
|
119
|
+
This option was implemented in Bundler 1\.4\.0 for Ruby 2\.0 or earlier\.
|
117
120
|
.
|
118
121
|
.IP "" 4
|
119
122
|
.
|
120
123
|
.nf
|
121
124
|
|
122
|
-
ruby "
|
125
|
+
ruby "3\.1\.2", patchlevel: "20"
|
123
126
|
.
|
124
127
|
.fi
|
125
128
|
.
|
@@ -265,6 +268,14 @@ C Ruby (MRI) only, but not Windows
|
|
265
268
|
Windows C Ruby (MRI), including RubyInstaller 32\-bit and 64\-bit versions
|
266
269
|
.
|
267
270
|
.TP
|
271
|
+
\fBmswin\fR
|
272
|
+
Windows C Ruby (MRI), including RubyInstaller 32\-bit versions
|
273
|
+
.
|
274
|
+
.TP
|
275
|
+
\fBmswin64\fR
|
276
|
+
Windows C Ruby (MRI), including RubyInstaller 64\-bit versions
|
277
|
+
.
|
278
|
+
.TP
|
268
279
|
\fBrbx\fR
|
269
280
|
Rubinius
|
270
281
|
.
|
@@ -277,13 +288,13 @@ JRuby
|
|
277
288
|
TruffleRuby
|
278
289
|
.
|
279
290
|
.P
|
280
|
-
On platforms \fBruby\fR, \fBmri\fR, and \fBwindows\fR, you may additionally specify a version by appending the major and minor version numbers without a delimiter\. For example, to specify that a gem should only be used on platform \fBruby\fR version
|
291
|
+
On platforms \fBruby\fR, \fBmri\fR, \fBmswin\fR, \fBmswin64\fR, and \fBwindows\fR, you may additionally specify a version by appending the major and minor version numbers without a delimiter\. For example, to specify that a gem should only be used on platform \fBruby\fR version 3\.1, use:
|
281
292
|
.
|
282
293
|
.IP "" 4
|
283
294
|
.
|
284
295
|
.nf
|
285
296
|
|
286
|
-
|
297
|
+
ruby_31
|
287
298
|
.
|
288
299
|
.fi
|
289
300
|
.
|
@@ -297,8 +308,8 @@ As with groups (above), you may specify one or more platforms:
|
|
297
308
|
.nf
|
298
309
|
|
299
310
|
gem "weakling", platforms: :jruby
|
300
|
-
gem "ruby\-debug", platforms: :
|
301
|
-
gem "nokogiri", platforms: [:
|
311
|
+
gem "ruby\-debug", platforms: :mri_31
|
312
|
+
gem "nokogiri", platforms: [:windows_31, :jruby]
|
302
313
|
.
|
303
314
|
.fi
|
304
315
|
.
|
@@ -497,7 +508,7 @@ Are both equivalent to
|
|
497
508
|
.
|
498
509
|
.nf
|
499
510
|
|
500
|
-
gem "rails", git: "
|
511
|
+
gem "rails", git: "https://github\.com/rails/rails\.git"
|
501
512
|
.
|
502
513
|
.fi
|
503
514
|
.
|
@@ -64,10 +64,10 @@ All parameters are `OPTIONAL` unless otherwise specified.
|
|
64
64
|
### VERSION (required)
|
65
65
|
|
66
66
|
The version of Ruby that your application requires. If your application
|
67
|
-
requires an alternate Ruby engine, such as JRuby,
|
67
|
+
requires an alternate Ruby engine, such as JRuby, TruffleRuby, etc., this
|
68
68
|
should be the Ruby version that the engine is compatible with.
|
69
69
|
|
70
|
-
ruby "1.
|
70
|
+
ruby "3.1.2"
|
71
71
|
|
72
72
|
### ENGINE
|
73
73
|
|
@@ -86,9 +86,10 @@ What exactly is an Engine?
|
|
86
86
|
|
87
87
|
- [Other implementations](https://www.ruby-lang.org/en/about/) of Ruby exist.
|
88
88
|
Some of the more well-known implementations include
|
89
|
-
[
|
89
|
+
[JRuby](http://jruby.org/) and [TruffleRuby](https://www.graalvm.org/ruby/).
|
90
90
|
Rubinius is an alternative implementation of Ruby written in Ruby.
|
91
91
|
JRuby is an implementation of Ruby on the JVM, short for Java Virtual Machine.
|
92
|
+
TruffleRuby is a Ruby implementation on the GraalVM, a language toolkit built on the JVM.
|
92
93
|
|
93
94
|
### ENGINE VERSION
|
94
95
|
|
@@ -96,13 +97,17 @@ Each application _may_ specify a Ruby engine version. If an engine version is
|
|
96
97
|
specified, an engine _must_ also be specified. If the engine is "ruby" the
|
97
98
|
engine version specified _must_ match the Ruby version.
|
98
99
|
|
99
|
-
ruby "
|
100
|
+
ruby "2.6.8", engine: "jruby", engine_version: "9.3.8.0"
|
100
101
|
|
101
102
|
### PATCHLEVEL
|
102
103
|
|
103
|
-
Each application _may_ specify a Ruby patchlevel.
|
104
|
+
Each application _may_ specify a Ruby patchlevel. Specifying the patchlevel has
|
105
|
+
been meaningless since Ruby 2.1.0 was released as the patchlevel is now
|
106
|
+
uniquely determined by a combination of major, minor, and teeny version numbers.
|
104
107
|
|
105
|
-
|
108
|
+
This option was implemented in Bundler 1.4.0 for Ruby 2.0 or earlier.
|
109
|
+
|
110
|
+
ruby "3.1.2", patchlevel: "20"
|
106
111
|
|
107
112
|
## GEMS
|
108
113
|
|
@@ -195,6 +200,10 @@ There are a number of `Gemfile` platforms:
|
|
195
200
|
C Ruby (MRI) only, but not Windows
|
196
201
|
* `windows`:
|
197
202
|
Windows C Ruby (MRI), including RubyInstaller 32-bit and 64-bit versions
|
203
|
+
* `mswin`:
|
204
|
+
Windows C Ruby (MRI), including RubyInstaller 32-bit versions
|
205
|
+
* `mswin64`:
|
206
|
+
Windows C Ruby (MRI), including RubyInstaller 64-bit versions
|
198
207
|
* `rbx`:
|
199
208
|
Rubinius
|
200
209
|
* `jruby`:
|
@@ -202,17 +211,18 @@ There are a number of `Gemfile` platforms:
|
|
202
211
|
* `truffleruby`:
|
203
212
|
TruffleRuby
|
204
213
|
|
205
|
-
On platforms `ruby`, `mri`, and `windows`, you may
|
206
|
-
by appending the major and minor version numbers
|
207
|
-
to specify that a gem should only be used on
|
214
|
+
On platforms `ruby`, `mri`, `mswin`, `mswin64`, and `windows`, you may
|
215
|
+
additionally specify a version by appending the major and minor version numbers
|
216
|
+
without a delimiter. For example, to specify that a gem should only be used on
|
217
|
+
platform `ruby` version 3.1, use:
|
208
218
|
|
209
|
-
|
219
|
+
ruby_31
|
210
220
|
|
211
221
|
As with groups (above), you may specify one or more platforms:
|
212
222
|
|
213
223
|
gem "weakling", platforms: :jruby
|
214
|
-
gem "ruby-debug", platforms: :
|
215
|
-
gem "nokogiri", platforms: [:
|
224
|
+
gem "ruby-debug", platforms: :mri_31
|
225
|
+
gem "nokogiri", platforms: [:windows_31, :jruby]
|
216
226
|
|
217
227
|
All operations involving groups ([`bundle install`](bundle-install.1.html), `Bundler.setup`,
|
218
228
|
`Bundler.require`) behave exactly the same as if any groups not
|
@@ -369,7 +379,7 @@ same, you can omit one.
|
|
369
379
|
|
370
380
|
Are both equivalent to
|
371
381
|
|
372
|
-
gem "rails", git: "
|
382
|
+
gem "rails", git: "https://github.com/rails/rails.git"
|
373
383
|
|
374
384
|
Since the `github` method is a specialization of `git_source`, it accepts a `:branch` named argument.
|
375
385
|
|
@@ -29,11 +29,15 @@ module Bundler
|
|
29
29
|
@platform = _remote_specification.platform
|
30
30
|
end
|
31
31
|
|
32
|
+
def identifier
|
33
|
+
@__identifier ||= [name, version, @platform.to_s]
|
34
|
+
end
|
35
|
+
|
32
36
|
def full_name
|
33
|
-
if @
|
37
|
+
if @platform == Gem::Platform::RUBY
|
34
38
|
"#{@name}-#{@version}"
|
35
39
|
else
|
36
|
-
"#{@name}-#{@version}-#{@
|
40
|
+
"#{@name}-#{@version}-#{@platform}"
|
37
41
|
end
|
38
42
|
end
|
39
43
|
|
@@ -40,7 +40,7 @@ module Bundler
|
|
40
40
|
base_requirements = {}
|
41
41
|
@base.each do |ls|
|
42
42
|
dep = Dependency.new(ls.name, ls.version)
|
43
|
-
base_requirements[ls.name] =
|
43
|
+
base_requirements[ls.name] = dep
|
44
44
|
end
|
45
45
|
@additional_base_requirements.each {|d| base_requirements[d.name] = d }
|
46
46
|
base_requirements
|
@@ -6,40 +6,23 @@ module Bundler
|
|
6
6
|
attr_accessor :name, :version, :source
|
7
7
|
attr_accessor :activated_platforms, :force_ruby_platform
|
8
8
|
|
9
|
-
def
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
new(specific_platform_specs.first, specs, platforms)
|
16
|
-
end
|
17
|
-
|
18
|
-
def initialize(exemplary_spec, specs, relevant_platforms)
|
19
|
-
@exemplary_spec = exemplary_spec
|
20
|
-
@name = exemplary_spec.name
|
21
|
-
@version = exemplary_spec.version
|
22
|
-
@source = exemplary_spec.source
|
9
|
+
def initialize(specs, relevant_platforms)
|
10
|
+
@exemplary_spec = specs.first
|
11
|
+
@name = @exemplary_spec.name
|
12
|
+
@version = @exemplary_spec.version
|
13
|
+
@source = @exemplary_spec.source
|
23
14
|
|
24
15
|
@activated_platforms = relevant_platforms
|
25
|
-
@dependencies = Hash.new do |dependencies, platforms|
|
26
|
-
dependencies[platforms] = dependencies_for(platforms)
|
27
|
-
end
|
28
16
|
@specs = specs
|
29
17
|
end
|
30
18
|
|
31
19
|
def to_specs
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
lazy_spec.force_ruby_platform = force_ruby_platform
|
39
|
-
lazy_spec.dependencies.replace s.dependencies
|
40
|
-
lazy_spec
|
41
|
-
end
|
42
|
-
end.flatten.compact.uniq
|
20
|
+
@specs.map do |s|
|
21
|
+
lazy_spec = LazySpecification.new(name, version, s.platform, source)
|
22
|
+
lazy_spec.force_ruby_platform = force_ruby_platform
|
23
|
+
lazy_spec.dependencies.replace s.dependencies
|
24
|
+
lazy_spec
|
25
|
+
end
|
43
26
|
end
|
44
27
|
|
45
28
|
def to_s
|
@@ -48,7 +31,9 @@ module Bundler
|
|
48
31
|
end
|
49
32
|
|
50
33
|
def dependencies_for_activated_platforms
|
51
|
-
@
|
34
|
+
@dependencies_for_activated_platforms ||= @specs.map do |spec|
|
35
|
+
__dependencies(spec) + metadata_dependencies(spec)
|
36
|
+
end.flatten.uniq
|
52
37
|
end
|
53
38
|
|
54
39
|
def ==(other)
|
@@ -79,35 +64,28 @@ module Bundler
|
|
79
64
|
|
80
65
|
private
|
81
66
|
|
82
|
-
def
|
83
|
-
platforms.map do |platform|
|
84
|
-
__dependencies(platform) + metadata_dependencies(platform)
|
85
|
-
end.flatten
|
86
|
-
end
|
87
|
-
|
88
|
-
def __dependencies(platform)
|
67
|
+
def __dependencies(spec)
|
89
68
|
dependencies = []
|
90
|
-
|
69
|
+
spec.dependencies.each do |dep|
|
91
70
|
next if dep.type == :development
|
92
|
-
dependencies <<
|
71
|
+
dependencies << Dependency.new(dep.name, dep.requirement)
|
93
72
|
end
|
94
73
|
dependencies
|
95
74
|
end
|
96
75
|
|
97
|
-
def metadata_dependencies(
|
98
|
-
spec = @specs[platform].first
|
76
|
+
def metadata_dependencies(spec)
|
99
77
|
return [] if spec.is_a?(LazySpecification)
|
100
78
|
|
101
79
|
[
|
102
|
-
metadata_dependency("Ruby", spec.required_ruby_version
|
103
|
-
metadata_dependency("RubyGems", spec.required_rubygems_version
|
80
|
+
metadata_dependency("Ruby", spec.required_ruby_version),
|
81
|
+
metadata_dependency("RubyGems", spec.required_rubygems_version),
|
104
82
|
].compact
|
105
83
|
end
|
106
84
|
|
107
|
-
def metadata_dependency(name, requirement
|
85
|
+
def metadata_dependency(name, requirement)
|
108
86
|
return if requirement.nil? || requirement.none?
|
109
87
|
|
110
|
-
|
88
|
+
Dependency.new("#{name}\0", requirement)
|
111
89
|
end
|
112
90
|
end
|
113
91
|
end
|
@@ -8,22 +8,6 @@ module Bundler
|
|
8
8
|
|
9
9
|
include GemHelpers
|
10
10
|
|
11
|
-
# Figures out the best possible configuration of gems that satisfies
|
12
|
-
# the list of passed dependencies and any child dependencies without
|
13
|
-
# causing any gem activation errors.
|
14
|
-
#
|
15
|
-
# ==== Parameters
|
16
|
-
# *dependencies<Gem::Dependency>:: The list of dependencies to resolve
|
17
|
-
#
|
18
|
-
# ==== Returns
|
19
|
-
# <GemBundle>,nil:: If the list of dependencies can be resolved, a
|
20
|
-
# collection of gemspecs is returned. Otherwise, nil is returned.
|
21
|
-
def self.resolve(requirements, source_requirements = {}, base = [], gem_version_promoter = GemVersionPromoter.new, additional_base_requirements = [], platforms = nil)
|
22
|
-
base = SpecSet.new(base) unless base.is_a?(SpecSet)
|
23
|
-
resolver = new(source_requirements, base, gem_version_promoter, additional_base_requirements, platforms)
|
24
|
-
resolver.start(requirements)
|
25
|
-
end
|
26
|
-
|
27
11
|
def initialize(source_requirements, base, gem_version_promoter, additional_base_requirements, platforms)
|
28
12
|
@source_requirements = source_requirements
|
29
13
|
@base = Resolver::Base.new(base, additional_base_requirements)
|
@@ -116,41 +100,35 @@ module Bundler
|
|
116
100
|
specification.dependencies_for_activated_platforms
|
117
101
|
end
|
118
102
|
|
119
|
-
def search_for(
|
120
|
-
|
121
|
-
|
122
|
-
name = dependency.name
|
123
|
-
@search_for[dependency_proxy] ||= begin
|
103
|
+
def search_for(dependency)
|
104
|
+
@search_for[dependency] ||= begin
|
105
|
+
name = dependency.name
|
124
106
|
locked_results = @base[name].select {|spec| requirement_satisfied_by?(dependency, nil, spec) }
|
125
107
|
locked_requirement = base_requirements[name]
|
126
108
|
results = results_for(dependency) + locked_results
|
127
109
|
results = results.select {|spec| requirement_satisfied_by?(locked_requirement, nil, spec) } if locked_requirement
|
110
|
+
dep_platforms = dependency.gem_platforms(@platforms)
|
128
111
|
|
129
|
-
|
130
|
-
|
112
|
+
@gem_version_promoter.sort_versions(dependency, results).group_by(&:version).reduce([]) do |groups, (_, specs)|
|
113
|
+
relevant_platforms = dep_platforms.select {|platform| specs.any? {|spec| spec.match_platform(platform) } }
|
114
|
+
next groups unless relevant_platforms.any?
|
131
115
|
|
132
|
-
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
|
116
|
+
ruby_specs = select_best_platform_match(specs, Gem::Platform::RUBY)
|
117
|
+
if ruby_specs.any?
|
118
|
+
spec_group_ruby = SpecGroup.new(ruby_specs, [Gem::Platform::RUBY])
|
119
|
+
spec_group_ruby.force_ruby_platform = dependency.force_ruby_platform
|
120
|
+
groups << spec_group_ruby
|
121
|
+
end
|
138
122
|
|
139
|
-
|
140
|
-
if spec_group_ruby
|
141
|
-
spec_group_ruby.force_ruby_platform = dependency.force_ruby_platform
|
142
|
-
groups << spec_group_ruby
|
143
|
-
end
|
123
|
+
next groups if @resolving_only_for_ruby || dependency.force_ruby_platform
|
144
124
|
|
145
|
-
|
125
|
+
platform_specs = relevant_platforms.flat_map {|platform| select_best_platform_match(specs, platform) }
|
126
|
+
next groups if platform_specs == ruby_specs
|
146
127
|
|
147
|
-
|
148
|
-
|
128
|
+
spec_group = SpecGroup.new(platform_specs, relevant_platforms)
|
129
|
+
groups << spec_group
|
149
130
|
|
150
|
-
|
151
|
-
end
|
152
|
-
else
|
153
|
-
[]
|
131
|
+
groups
|
154
132
|
end
|
155
133
|
end
|
156
134
|
end
|
@@ -181,10 +159,6 @@ module Bundler
|
|
181
159
|
requirement.matches_spec?(spec) || spec.source.is_a?(Source::Gemspec)
|
182
160
|
end
|
183
161
|
|
184
|
-
def dependencies_equal?(dependencies, other_dependencies)
|
185
|
-
dependencies.map(&:dep) == other_dependencies.map(&:dep)
|
186
|
-
end
|
187
|
-
|
188
162
|
def sort_dependencies(dependencies, activated, conflicts)
|
189
163
|
dependencies.sort_by do |dependency|
|
190
164
|
name = name_for(dependency)
|
@@ -196,17 +170,10 @@ module Bundler
|
|
196
170
|
amount_constrained(dependency),
|
197
171
|
conflicts[name] ? 0 : 1,
|
198
172
|
vertex.payload ? 0 : search_for(dependency).count,
|
199
|
-
self.class.platform_sort_key(dependency.__platform),
|
200
173
|
]
|
201
174
|
end
|
202
175
|
end
|
203
176
|
|
204
|
-
def self.platform_sort_key(platform)
|
205
|
-
# Prefer specific platform to not specific platform
|
206
|
-
return ["99-LAST", "", "", ""] if Gem::Platform::RUBY == platform
|
207
|
-
["00", *platform.to_a.map {|part| part || "" }]
|
208
|
-
end
|
209
|
-
|
210
177
|
private
|
211
178
|
|
212
179
|
def base_requirements
|
@@ -261,21 +228,11 @@ module Bundler
|
|
261
228
|
requirements.map! do |requirement|
|
262
229
|
name = requirement.name
|
263
230
|
next requirement if name == "bundler"
|
231
|
+
next if requirement.gem_platforms(@platforms).empty?
|
264
232
|
next requirement unless search_for(requirement).empty?
|
265
233
|
next unless requirement.current_platform?
|
266
234
|
|
267
|
-
|
268
|
-
version = base.first.version
|
269
|
-
message = "You have requested:\n" \
|
270
|
-
" #{name} #{requirement.requirement}\n\n" \
|
271
|
-
"The bundle currently has #{name} locked at #{version}.\n" \
|
272
|
-
"Try running `bundle update #{name}`\n\n" \
|
273
|
-
"If you are updating multiple gems in your Gemfile at once,\n" \
|
274
|
-
"try passing them all to `bundle update`"
|
275
|
-
else
|
276
|
-
message = gem_not_found_message(name, requirement, source_for(name))
|
277
|
-
end
|
278
|
-
raise GemNotFound, message
|
235
|
+
raise GemNotFound, gem_not_found_message(name, requirement, source_for(name))
|
279
236
|
end.compact!
|
280
237
|
end
|
281
238
|
|
@@ -293,7 +250,9 @@ module Bundler
|
|
293
250
|
if specs_matching_requirement.any?
|
294
251
|
specs = specs_matching_requirement
|
295
252
|
matching_part = requirement_label
|
296
|
-
|
253
|
+
platforms = requirement.gem_platforms(@platforms)
|
254
|
+
platform_label = platforms.size == 1 ? "platform '#{platforms.first}" : "platforms '#{platforms.join("', '")}"
|
255
|
+
requirement_label = "#{requirement_label}' with #{platform_label}"
|
297
256
|
end
|
298
257
|
|
299
258
|
message = String.new("Could not find gem '#{requirement_label}'#{extra_message} in #{source}#{cache_message}.\n")
|
@@ -163,7 +163,7 @@ module Bundler
|
|
163
163
|
"\nEither installing with `--full-index` or running `bundle update #{spec.name}` should fix the problem."
|
164
164
|
end
|
165
165
|
|
166
|
-
def pretty_dependency(dep
|
166
|
+
def pretty_dependency(dep)
|
167
167
|
msg = String.new(dep.name)
|
168
168
|
msg << " (#{dep.requirement})" unless dep.requirement == Gem::Requirement.default
|
169
169
|
|
@@ -172,7 +172,6 @@ module Bundler
|
|
172
172
|
msg << " " << platform_string if !platform_string.empty? && platform_string != Gem::Platform::RUBY
|
173
173
|
end
|
174
174
|
|
175
|
-
msg << " from the `#{dep.source}` source" if print_source && dep.source
|
176
175
|
msg
|
177
176
|
end
|
178
177
|
|
data/bundler/lib/bundler.rb
CHANGED
@@ -41,7 +41,6 @@ module Bundler
|
|
41
41
|
|
42
42
|
autoload :Definition, File.expand_path("bundler/definition", __dir__)
|
43
43
|
autoload :Dependency, File.expand_path("bundler/dependency", __dir__)
|
44
|
-
autoload :DepProxy, File.expand_path("bundler/dep_proxy", __dir__)
|
45
44
|
autoload :Deprecate, File.expand_path("bundler/deprecate", __dir__)
|
46
45
|
autoload :Digest, File.expand_path("bundler/digest", __dir__)
|
47
46
|
autoload :Dsl, File.expand_path("bundler/dsl", __dir__)
|
@@ -16,7 +16,7 @@ if RUBY_VERSION >= "2.5" && !Gem::KERNEL_WARN_IGNORES_INTERNAL_ENTRIES
|
|
16
16
|
|
17
17
|
module_function define_method(:warn) {|*messages, **kw|
|
18
18
|
unless uplevel = kw[:uplevel]
|
19
|
-
if Gem.java_platform?
|
19
|
+
if Gem.java_platform? && RUBY_VERSION < "3.1"
|
20
20
|
return original_warn.bind(self).call(*messages)
|
21
21
|
else
|
22
22
|
return original_warn.bind(self).call(*messages, **kw)
|
@@ -214,7 +214,7 @@ class Gem::RequestSet::GemDependencyAPI
|
|
214
214
|
git_source :github do |repo_name|
|
215
215
|
repo_name = "#{repo_name}/#{repo_name}" unless repo_name.include? "/"
|
216
216
|
|
217
|
-
"
|
217
|
+
"https://github.com/#{repo_name}.git"
|
218
218
|
end
|
219
219
|
|
220
220
|
git_source :bitbucket do |repo_name|
|
data/lib/rubygems.rb
CHANGED
data/rubygems-update.gemspec
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
Gem::Specification.new do |s|
|
4
4
|
s.name = "rubygems-update"
|
5
|
-
s.version = "3.3.
|
5
|
+
s.version = "3.3.25"
|
6
6
|
s.authors = ["Jim Weirich", "Chad Fowler", "Eric Hodel", "Luis Lavena", "Aaron Patterson", "Samuel Giddins", "André Arko", "Evan Phoenix", "Hiroshi SHIBATA"]
|
7
7
|
s.email = ["", "", "drbrain@segment7.net", "luislavena@gmail.com", "aaron@tenderlovemaking.com", "segiddins@segiddins.me", "andre@arko.net", "evan@phx.io", "hsbt@ruby-lang.org"]
|
8
8
|
|
@@ -1,19 +1,19 @@
|
|
1
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