bundler 2.2.29 → 2.2.33
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 +79 -1
- data/README.md +1 -1
- data/lib/bundler/build_metadata.rb +2 -2
- data/lib/bundler/cli/doctor.rb +3 -2
- data/lib/bundler/cli/gem.rb +69 -7
- data/lib/bundler/cli/info.rb +16 -4
- data/lib/bundler/cli/issue.rb +4 -3
- data/lib/bundler/cli/update.rb +2 -2
- data/lib/bundler/cli.rb +4 -1
- data/lib/bundler/compact_index_client/updater.rb +0 -5
- data/lib/bundler/compact_index_client.rb +2 -2
- data/lib/bundler/definition.rb +62 -124
- data/lib/bundler/digest.rb +71 -0
- data/lib/bundler/dsl.rb +18 -3
- data/lib/bundler/environment_preserver.rb +4 -1
- data/lib/bundler/errors.rb +18 -2
- data/lib/bundler/fetcher.rb +2 -1
- data/lib/bundler/friendly_errors.rb +5 -30
- data/lib/bundler/gem_helper.rb +5 -16
- data/lib/bundler/lazy_specification.rb +17 -1
- data/lib/bundler/lockfile_parser.rb +1 -0
- data/lib/bundler/man/bundle-add.1 +1 -1
- data/lib/bundler/man/bundle-binstubs.1 +1 -1
- data/lib/bundler/man/bundle-cache.1 +1 -1
- data/lib/bundler/man/bundle-check.1 +1 -1
- data/lib/bundler/man/bundle-clean.1 +1 -1
- data/lib/bundler/man/bundle-config.1 +3 -3
- data/lib/bundler/man/bundle-config.1.ronn +2 -2
- data/lib/bundler/man/bundle-doctor.1 +1 -1
- data/lib/bundler/man/bundle-exec.1 +1 -1
- data/lib/bundler/man/bundle-gem.1 +14 -1
- data/lib/bundler/man/bundle-gem.1.ronn +16 -0
- data/lib/bundler/man/bundle-info.1 +1 -1
- data/lib/bundler/man/bundle-init.1 +1 -1
- data/lib/bundler/man/bundle-inject.1 +1 -1
- data/lib/bundler/man/bundle-install.1 +1 -1
- data/lib/bundler/man/bundle-list.1 +1 -1
- data/lib/bundler/man/bundle-lock.1 +1 -1
- data/lib/bundler/man/bundle-open.1 +1 -1
- data/lib/bundler/man/bundle-outdated.1 +1 -1
- data/lib/bundler/man/bundle-platform.1 +1 -1
- data/lib/bundler/man/bundle-pristine.1 +1 -1
- data/lib/bundler/man/bundle-remove.1 +1 -1
- data/lib/bundler/man/bundle-show.1 +1 -1
- data/lib/bundler/man/bundle-update.1 +1 -1
- data/lib/bundler/man/bundle-viz.1 +1 -1
- data/lib/bundler/man/bundle.1 +1 -1
- data/lib/bundler/man/gemfile.5 +27 -1
- data/lib/bundler/man/gemfile.5.ronn +8 -0
- data/lib/bundler/plugin/api/source.rb +1 -0
- data/lib/bundler/resolver.rb +2 -4
- data/lib/bundler/rubygems_ext.rb +4 -0
- data/lib/bundler/rubygems_gem_installer.rb +20 -4
- data/lib/bundler/rubygems_integration.rb +26 -9
- data/lib/bundler/runtime.rb +2 -2
- data/lib/bundler/shared_helpers.rb +2 -3
- data/lib/bundler/source/git/git_proxy.rb +7 -4
- data/lib/bundler/source/git.rb +3 -1
- data/lib/bundler/source/rubygems.rb +52 -84
- data/lib/bundler/source/rubygems_aggregate.rb +1 -1
- data/lib/bundler/source.rb +1 -1
- data/lib/bundler/source_list.rb +7 -29
- data/lib/bundler/spec_set.rb +1 -1
- data/lib/bundler/templates/newgem/Gemfile.tt +5 -2
- data/lib/bundler/templates/newgem/Rakefile.tt +5 -1
- data/lib/bundler/templates/newgem/github/workflows/main.yml.tt +2 -2
- data/lib/bundler/templates/newgem/newgem.gemspec.tt +12 -12
- data/lib/bundler/templates/newgem/sig/newgem.rbs.tt +8 -0
- data/lib/bundler/templates/newgem/standard.yml.tt +2 -0
- data/lib/bundler/vendor/.document +1 -0
- data/lib/bundler/vendor/connection_pool/LICENSE +20 -0
- data/lib/bundler/vendor/connection_pool/lib/connection_pool/timed_stack.rb +19 -21
- data/lib/bundler/vendor/connection_pool/lib/connection_pool/version.rb +1 -1
- data/lib/bundler/vendor/connection_pool/lib/connection_pool/wrapper.rb +57 -0
- data/lib/bundler/vendor/connection_pool/lib/connection_pool.rb +39 -74
- data/lib/bundler/vendor/fileutils/LICENSE.txt +22 -0
- data/lib/bundler/vendor/molinillo/LICENSE +9 -0
- data/lib/bundler/vendor/molinillo/lib/molinillo/dependency_graph.rb +2 -2
- data/lib/bundler/vendor/net-http-persistent/README.rdoc +82 -0
- data/lib/bundler/vendor/thor/LICENSE.md +20 -0
- data/lib/bundler/vendor/tsort/LICENSE.txt +22 -0
- data/lib/bundler/vendor/tsort/lib/tsort.rb +453 -0
- data/lib/bundler/vendor/uri/LICENSE.txt +22 -0
- data/lib/bundler/vendored_tsort.rb +4 -0
- data/lib/bundler/version.rb +1 -1
- data/lib/bundler/worker.rb +2 -2
- data/lib/bundler.rb +2 -1
- metadata +20 -7
- data/lib/bundler/vendor/connection_pool/lib/connection_pool/monotonic_time.rb +0 -66
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 889ebea9ec62ae3ec9d4c7cfc9e5d99db2e48244890b93c3c1e5e6636cbbaae3
|
|
4
|
+
data.tar.gz: 28c8ff7149d6182d8cea46d9576d74e8a41115ef5243f253c6c7d023c23f28a4
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 1d949abc82fbe2f91e1ffebacb9dcb6f3366b4f0650ce96bfedd671965622e75d1a9cf2f6be762e8b7aa05a86eea2085f7834c2f23457c29b851eece9df81f78
|
|
7
|
+
data.tar.gz: f997fd1c1bfef3b9164cfefe9a4c5f092c870967dfc0352f5ac4b01a16bb2bb9c974511fb6b5126563672b736dc020f450a7b3ebfb0156757d26f41c3a2651de
|
data/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,81 @@
|
|
|
1
|
+
# 2.2.33 (December 7, 2021)
|
|
2
|
+
|
|
3
|
+
## Security fixes:
|
|
4
|
+
|
|
5
|
+
- Pass "--" to git commands to separate positional and optional args [#5142](https://github.com/rubygems/rubygems/pull/5142)
|
|
6
|
+
|
|
7
|
+
## Enhancements:
|
|
8
|
+
|
|
9
|
+
- Accept pull request URLs as github source [#5126](https://github.com/rubygems/rubygems/pull/5126)
|
|
10
|
+
- Add `--version` parameter to `bundle info` command [#5137](https://github.com/rubygems/rubygems/pull/5137)
|
|
11
|
+
- Let original `Errno::EACCES` error be raised in compact index updater [#5110](https://github.com/rubygems/rubygems/pull/5110)
|
|
12
|
+
- Improve gemfile-lockfile source equivalence errors [#5120](https://github.com/rubygems/rubygems/pull/5120)
|
|
13
|
+
- Avoid float-to-string loss of characters in GitHub Actions configuration labels in new gem template [#5089](https://github.com/rubygems/rubygems/pull/5089)
|
|
14
|
+
- Add an initial rbs template to `bundle gem` skeleton [#5041](https://github.com/rubygems/rubygems/pull/5041)
|
|
15
|
+
- Avoid shared libraries not getting environment passed right after argv in memory when `bundle exec` is used [#4815](https://github.com/rubygems/rubygems/pull/4815)
|
|
16
|
+
|
|
17
|
+
## Bug fixes:
|
|
18
|
+
|
|
19
|
+
- Don't cleanup paths from gems already activated from `$LOAD_PATH` [#5111](https://github.com/rubygems/rubygems/pull/5111)
|
|
20
|
+
- Fix handling prereleases of 0 versions, like 0.0.0.dev or 0.0.0.SNAPSHOT [#5116](https://github.com/rubygems/rubygems/pull/5116)
|
|
21
|
+
- Fix escape of filenames in `bundle doctor` [#5102](https://github.com/rubygems/rubygems/pull/5102)
|
|
22
|
+
- Don't unlock dependencies when running `bundle install` after changing global source [#5090](https://github.com/rubygems/rubygems/pull/5090)
|
|
23
|
+
- Fix missing locked specs when depended on another platform [#5092](https://github.com/rubygems/rubygems/pull/5092)
|
|
24
|
+
- Fix `bundle info` sometimes claiming that bundler has been deleted [#5097](https://github.com/rubygems/rubygems/pull/5097)
|
|
25
|
+
|
|
26
|
+
## Documentation:
|
|
27
|
+
|
|
28
|
+
- Ignore to generate the documentation from vendored libraries [#5118](https://github.com/rubygems/rubygems/pull/5118)
|
|
29
|
+
|
|
30
|
+
# 2.2.32 (November 23, 2021)
|
|
31
|
+
|
|
32
|
+
## Enhancements:
|
|
33
|
+
|
|
34
|
+
- Clarify `bundle viz` deprecation [#5083](https://github.com/rubygems/rubygems/pull/5083)
|
|
35
|
+
- Unlock dependencies that no longer match lockfile [#5068](https://github.com/rubygems/rubygems/pull/5068)
|
|
36
|
+
- Use `shellsplit` instead of array of strings for git push [#5062](https://github.com/rubygems/rubygems/pull/5062)
|
|
37
|
+
- Re-enable `default_ignores` option for standard [#5003](https://github.com/rubygems/rubygems/pull/5003)
|
|
38
|
+
|
|
39
|
+
## Bug fixes:
|
|
40
|
+
|
|
41
|
+
- Fix downgrading dependencies by changing the `Gemfile` and running `bundle update` [#5078](https://github.com/rubygems/rubygems/pull/5078)
|
|
42
|
+
|
|
43
|
+
# 2.2.31 (November 8, 2021)
|
|
44
|
+
|
|
45
|
+
## Enhancements:
|
|
46
|
+
|
|
47
|
+
- Link to working `bundler-graph` plugin in `bundle viz` deprecation message [#5061](https://github.com/rubygems/rubygems/pull/5061)
|
|
48
|
+
- Memoize materialized specs when requiring `bundler/setup` [#5033](https://github.com/rubygems/rubygems/pull/5033)
|
|
49
|
+
- Allow custom LicenseRef [#5013](https://github.com/rubygems/rubygems/pull/5013)
|
|
50
|
+
- Better error when installing a lockfile with git sources and git is not installed [#5036](https://github.com/rubygems/rubygems/pull/5036)
|
|
51
|
+
- Only delete cached gem when it's corrupted [#5031](https://github.com/rubygems/rubygems/pull/5031)
|
|
52
|
+
- Support gemified `tsort` [#5032](https://github.com/rubygems/rubygems/pull/5032)
|
|
53
|
+
- Add standard option alongside rubocop to `bundle gem` [#4411](https://github.com/rubygems/rubygems/pull/4411)
|
|
54
|
+
|
|
55
|
+
## Bug fixes:
|
|
56
|
+
|
|
57
|
+
- Fix system man pages no longer working after bundler overrides `MANPATH` [#5039](https://github.com/rubygems/rubygems/pull/5039)
|
|
58
|
+
- Don't warn when a lockfile is locked to a dev version [#5018](https://github.com/rubygems/rubygems/pull/5018)
|
|
59
|
+
|
|
60
|
+
# 2.2.30 (October 26, 2021)
|
|
61
|
+
|
|
62
|
+
## Enhancements:
|
|
63
|
+
|
|
64
|
+
- Add a custom SHA1 digest implementation to no longer depend on the digest gem before we know which version to activate [#4989](https://github.com/rubygems/rubygems/pull/4989)
|
|
65
|
+
- Ensure vendored gems have licenses [#4998](https://github.com/rubygems/rubygems/pull/4998)
|
|
66
|
+
- Update broken link in Bundler::Fetcher::CertificateFailureError [#4987](https://github.com/rubygems/rubygems/pull/4987)
|
|
67
|
+
- Give better errors for some permission issues [#4965](https://github.com/rubygems/rubygems/pull/4965)
|
|
68
|
+
- Print better errors when `bundler/gem_tasks` fail [#4872](https://github.com/rubygems/rubygems/pull/4872)
|
|
69
|
+
- Fix `bundle install` to reinstall deleted gems [#4974](https://github.com/rubygems/rubygems/pull/4974)
|
|
70
|
+
- Unify issue template and ISSUES.md document [#4980](https://github.com/rubygems/rubygems/pull/4980)
|
|
71
|
+
- Bump vendored connection_pool to 2.2.5 [#4738](https://github.com/rubygems/rubygems/pull/4738)
|
|
72
|
+
|
|
73
|
+
## Bug fixes:
|
|
74
|
+
|
|
75
|
+
- Fix error message pointing to non existing file when using a global gem cache [#4999](https://github.com/rubygems/rubygems/pull/4999)
|
|
76
|
+
- Fix install crash when lockfile has missing dependencies for the current platform [#4941](https://github.com/rubygems/rubygems/pull/4941)
|
|
77
|
+
- Make `bundle info` show a proper warning every time it finds a deleted gem [#4971](https://github.com/rubygems/rubygems/pull/4971)
|
|
78
|
+
|
|
1
79
|
# 2.2.29 (October 8, 2021)
|
|
2
80
|
|
|
3
81
|
## Enhancements:
|
|
@@ -107,7 +185,7 @@
|
|
|
107
185
|
- Fix `bundle doctor` crashing when finding a broken symlink [#4707](https://github.com/rubygems/rubygems/pull/4707)
|
|
108
186
|
- Fix incorrect re-resolve edge case [#4700](https://github.com/rubygems/rubygems/pull/4700)
|
|
109
187
|
- Fix some gems being unintentionally locked under multiple lockfile sections [#4701](https://github.com/rubygems/rubygems/pull/4701)
|
|
110
|
-
- Fix `--conservative` flag unexpectedly updating indirect dependencies [#4692](https://github.com/rubygems/rubygems/pull/4692)
|
|
188
|
+
- Fix `--conservative` flag unexpectedly updating indirect dependencies. NOTE: As part of this bug fix, some undocumented, unintentional code causing `bundle update --source <gem>` to update conservatively was fixed. Use the documented `bundle update --conservative <gem>` instead [#4692](https://github.com/rubygems/rubygems/pull/4692)
|
|
111
189
|
|
|
112
190
|
# 2.2.21 (June 23, 2021)
|
|
113
191
|
|
data/README.md
CHANGED
|
@@ -32,7 +32,7 @@ See [bundler.io](https://bundler.io) for the full documentation.
|
|
|
32
32
|
|
|
33
33
|
For help with common problems, see [TROUBLESHOOTING](doc/TROUBLESHOOTING.md).
|
|
34
34
|
|
|
35
|
-
Still stuck? Try [filing an issue](
|
|
35
|
+
Still stuck? Try [filing an issue](https://github.com/rubygems/rubygems/issues/new?labels=Bundler&template=bundler-related-issue.md).
|
|
36
36
|
|
|
37
37
|
### Other questions
|
|
38
38
|
|
|
@@ -4,8 +4,8 @@ module Bundler
|
|
|
4
4
|
# Represents metadata from when the Bundler gem was built.
|
|
5
5
|
module BuildMetadata
|
|
6
6
|
# begin ivars
|
|
7
|
-
@built_at = "2021-
|
|
8
|
-
@git_commit_sha = "
|
|
7
|
+
@built_at = "2021-12-07".freeze
|
|
8
|
+
@git_commit_sha = "9b5e2a350b".freeze
|
|
9
9
|
@release = true
|
|
10
10
|
# end ivars
|
|
11
11
|
|
data/lib/bundler/cli/doctor.rb
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
3
|
require "rbconfig"
|
|
4
|
+
require "shellwords"
|
|
4
5
|
|
|
5
6
|
module Bundler
|
|
6
7
|
class CLI::Doctor
|
|
@@ -22,14 +23,14 @@ module Bundler
|
|
|
22
23
|
end
|
|
23
24
|
|
|
24
25
|
def dylibs_darwin(path)
|
|
25
|
-
output = `/usr/bin/otool -L
|
|
26
|
+
output = `/usr/bin/otool -L #{path.shellescape}`.chomp
|
|
26
27
|
dylibs = output.split("\n")[1..-1].map {|l| l.match(DARWIN_REGEX).captures[0] }.uniq
|
|
27
28
|
# ignore @rpath and friends
|
|
28
29
|
dylibs.reject {|dylib| dylib.start_with? "@" }
|
|
29
30
|
end
|
|
30
31
|
|
|
31
32
|
def dylibs_ldd(path)
|
|
32
|
-
output = `/usr/bin/ldd
|
|
33
|
+
output = `/usr/bin/ldd #{path.shellescape}`.chomp
|
|
33
34
|
output.split("\n").map do |l|
|
|
34
35
|
match = l.match(LDD_REGEX)
|
|
35
36
|
next if match.nil?
|
data/lib/bundler/cli/gem.rb
CHANGED
|
@@ -76,6 +76,7 @@ module Bundler
|
|
|
76
76
|
"#{Bundler.preferred_gemfile_name}.tt" => Bundler.preferred_gemfile_name,
|
|
77
77
|
"lib/newgem.rb.tt" => "lib/#{namespaced_path}.rb",
|
|
78
78
|
"lib/newgem/version.rb.tt" => "lib/#{namespaced_path}/version.rb",
|
|
79
|
+
"sig/newgem.rbs.tt" => "sig/#{namespaced_path}.rbs",
|
|
79
80
|
"newgem.gemspec.tt" => "#{name}.gemspec",
|
|
80
81
|
"Rakefile.tt" => "Rakefile",
|
|
81
82
|
"README.md.tt" => "README.md",
|
|
@@ -163,15 +164,16 @@ module Bundler
|
|
|
163
164
|
templates.merge!("CHANGELOG.md.tt" => "CHANGELOG.md")
|
|
164
165
|
end
|
|
165
166
|
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
"and the Ruby Style Guides (https://github.com/rubocop-hq/ruby-style-guide).")
|
|
171
|
-
config[:rubocop] = true
|
|
172
|
-
config[:rubocop_version] = rubocop_version
|
|
167
|
+
config[:linter] = ask_and_set_linter
|
|
168
|
+
case config[:linter]
|
|
169
|
+
when "rubocop"
|
|
170
|
+
config[:linter_version] = rubocop_version
|
|
173
171
|
Bundler.ui.info "RuboCop enabled in config"
|
|
174
172
|
templates.merge!("rubocop.yml.tt" => ".rubocop.yml")
|
|
173
|
+
when "standard"
|
|
174
|
+
config[:linter_version] = standard_version
|
|
175
|
+
Bundler.ui.info "Standard enabled in config"
|
|
176
|
+
templates.merge!("standard.yml.tt" => ".standard.yml")
|
|
175
177
|
end
|
|
176
178
|
|
|
177
179
|
templates.merge!("exe/newgem.tt" => "exe/#{name}") if config[:exe]
|
|
@@ -317,6 +319,58 @@ module Bundler
|
|
|
317
319
|
ci_template
|
|
318
320
|
end
|
|
319
321
|
|
|
322
|
+
def ask_and_set_linter
|
|
323
|
+
linter_template = options[:linter] || Bundler.settings["gem.linter"]
|
|
324
|
+
linter_template = deprecated_rubocop_option if linter_template.nil?
|
|
325
|
+
|
|
326
|
+
if linter_template.to_s.empty?
|
|
327
|
+
Bundler.ui.confirm "Do you want to add a code linter and formatter to your gem? " \
|
|
328
|
+
"Supported Linters:\n" \
|
|
329
|
+
"* RuboCop: https://rubocop.org\n" \
|
|
330
|
+
"* Standard: https://github.com/testdouble/standard\n" \
|
|
331
|
+
"\n"
|
|
332
|
+
Bundler.ui.info hint_text("linter")
|
|
333
|
+
|
|
334
|
+
result = Bundler.ui.ask "Enter a linter. rubocop/standard/(none):"
|
|
335
|
+
if result =~ /rubocop|standard/
|
|
336
|
+
linter_template = result
|
|
337
|
+
else
|
|
338
|
+
linter_template = false
|
|
339
|
+
end
|
|
340
|
+
end
|
|
341
|
+
|
|
342
|
+
if Bundler.settings["gem.linter"].nil?
|
|
343
|
+
Bundler.settings.set_global("gem.linter", linter_template)
|
|
344
|
+
end
|
|
345
|
+
|
|
346
|
+
# Once gem.linter safely set, unset the deprecated gem.rubocop
|
|
347
|
+
unless Bundler.settings["gem.rubocop"].nil?
|
|
348
|
+
Bundler.settings.set_global("gem.rubocop", nil)
|
|
349
|
+
end
|
|
350
|
+
|
|
351
|
+
if options[:linter] == Bundler.settings["gem.linter"]
|
|
352
|
+
Bundler.ui.info "#{options[:linter]} is already configured, ignoring --linter flag."
|
|
353
|
+
end
|
|
354
|
+
|
|
355
|
+
linter_template
|
|
356
|
+
end
|
|
357
|
+
|
|
358
|
+
def deprecated_rubocop_option
|
|
359
|
+
if !options[:rubocop].nil?
|
|
360
|
+
if options[:rubocop]
|
|
361
|
+
Bundler::SharedHelpers.major_deprecation 2, "--rubocop is deprecated, use --linter=rubocop"
|
|
362
|
+
"rubocop"
|
|
363
|
+
else
|
|
364
|
+
Bundler::SharedHelpers.major_deprecation 2, "--no-rubocop is deprecated, use --linter"
|
|
365
|
+
false
|
|
366
|
+
end
|
|
367
|
+
elsif !Bundler.settings["gem.rubocop"].nil?
|
|
368
|
+
Bundler::SharedHelpers.major_deprecation 2,
|
|
369
|
+
"config gem.rubocop is deprecated; we've updated your config to use gem.linter instead"
|
|
370
|
+
Bundler.settings["gem.rubocop"] ? "rubocop" : false
|
|
371
|
+
end
|
|
372
|
+
end
|
|
373
|
+
|
|
320
374
|
def bundler_dependency_version
|
|
321
375
|
v = Gem::Version.new(Bundler::VERSION)
|
|
322
376
|
req = v.segments[0..1]
|
|
@@ -367,5 +421,13 @@ module Bundler
|
|
|
367
421
|
"1.21"
|
|
368
422
|
end
|
|
369
423
|
end
|
|
424
|
+
|
|
425
|
+
def standard_version
|
|
426
|
+
if Gem.ruby_version < Gem::Version.new("2.4.a") then "0.2.5"
|
|
427
|
+
elsif Gem.ruby_version < Gem::Version.new("2.5.a") then "1.0"
|
|
428
|
+
else
|
|
429
|
+
"1.3"
|
|
430
|
+
end
|
|
431
|
+
end
|
|
370
432
|
end
|
|
371
433
|
end
|
data/lib/bundler/cli/info.rb
CHANGED
|
@@ -18,6 +18,7 @@ module Bundler
|
|
|
18
18
|
|
|
19
19
|
if spec
|
|
20
20
|
return print_gem_path(spec) if @options[:path]
|
|
21
|
+
return print_gem_version(spec) if @options[:version]
|
|
21
22
|
print_gem_info(spec)
|
|
22
23
|
end
|
|
23
24
|
end
|
|
@@ -39,13 +40,18 @@ module Bundler
|
|
|
39
40
|
raise GemNotFound, Bundler::CLI::Common.gem_not_found_message(gem_name, Bundler.definition.dependencies)
|
|
40
41
|
end
|
|
41
42
|
|
|
43
|
+
def print_gem_version(spec)
|
|
44
|
+
Bundler.ui.info spec.version.to_s
|
|
45
|
+
end
|
|
46
|
+
|
|
42
47
|
def print_gem_path(spec)
|
|
43
|
-
|
|
48
|
+
name = spec.name
|
|
49
|
+
if name == "bundler"
|
|
44
50
|
path = File.expand_path("../../../..", __FILE__)
|
|
45
51
|
else
|
|
46
52
|
path = spec.full_gem_path
|
|
47
|
-
|
|
48
|
-
return Bundler.ui.warn "The gem #{
|
|
53
|
+
if spec.deleted_gem?
|
|
54
|
+
return Bundler.ui.warn "The gem #{name} has been deleted. It was installed at: #{path}"
|
|
49
55
|
end
|
|
50
56
|
end
|
|
51
57
|
|
|
@@ -54,8 +60,9 @@ module Bundler
|
|
|
54
60
|
|
|
55
61
|
def print_gem_info(spec)
|
|
56
62
|
metadata = spec.metadata
|
|
63
|
+
name = spec.name
|
|
57
64
|
gem_info = String.new
|
|
58
|
-
gem_info << " * #{
|
|
65
|
+
gem_info << " * #{name} (#{spec.version}#{spec.git_version})\n"
|
|
59
66
|
gem_info << "\tSummary: #{spec.summary}\n" if spec.summary
|
|
60
67
|
gem_info << "\tHomepage: #{spec.homepage}\n" if spec.homepage
|
|
61
68
|
gem_info << "\tDocumentation: #{metadata["documentation_uri"]}\n" if metadata.key?("documentation_uri")
|
|
@@ -67,6 +74,11 @@ module Bundler
|
|
|
67
74
|
gem_info << "\tMailing List: #{metadata["mailing_list_uri"]}\n" if metadata.key?("mailing_list_uri")
|
|
68
75
|
gem_info << "\tPath: #{spec.full_gem_path}\n"
|
|
69
76
|
gem_info << "\tDefault Gem: yes" if spec.respond_to?(:default_gem?) && spec.default_gem?
|
|
77
|
+
|
|
78
|
+
if name != "bundler" && spec.deleted_gem?
|
|
79
|
+
return Bundler.ui.warn "The gem #{name} has been deleted. Gemspec information is still available though:\n#{gem_info}"
|
|
80
|
+
end
|
|
81
|
+
|
|
70
82
|
Bundler.ui.info gem_info
|
|
71
83
|
end
|
|
72
84
|
end
|
data/lib/bundler/cli/issue.rb
CHANGED
|
@@ -20,9 +20,10 @@ module Bundler
|
|
|
20
20
|
|
|
21
21
|
Hopefully the troubleshooting steps above resolved your problem! If things
|
|
22
22
|
still aren't working the way you expect them to, please let us know so
|
|
23
|
-
that we can diagnose and help fix the problem you're having
|
|
24
|
-
|
|
25
|
-
https://github.com/rubygems/rubygems/
|
|
23
|
+
that we can diagnose and help fix the problem you're having, by filling
|
|
24
|
+
in the new issue form located at
|
|
25
|
+
https://github.com/rubygems/rubygems/issues/new?labels=Bundler&template=bundler-related-issue.md,
|
|
26
|
+
and copy and pasting the information below.
|
|
26
27
|
|
|
27
28
|
EOS
|
|
28
29
|
|
data/lib/bundler/cli/update.rb
CHANGED
|
@@ -66,7 +66,7 @@ module Bundler
|
|
|
66
66
|
|
|
67
67
|
if locked_gems = Bundler.definition.locked_gems
|
|
68
68
|
previous_locked_info = locked_gems.specs.reduce({}) do |h, s|
|
|
69
|
-
h[s.name] = { :spec => s, :version => s.version, :source => s.source.
|
|
69
|
+
h[s.name] = { :spec => s, :version => s.version, :source => s.source.identifier }
|
|
70
70
|
h
|
|
71
71
|
end
|
|
72
72
|
end
|
|
@@ -95,7 +95,7 @@ module Bundler
|
|
|
95
95
|
end
|
|
96
96
|
|
|
97
97
|
locked_source = locked_info[:source]
|
|
98
|
-
new_source = new_spec.source.
|
|
98
|
+
new_source = new_spec.source.identifier
|
|
99
99
|
next if locked_source != new_source
|
|
100
100
|
|
|
101
101
|
new_version = new_spec.version
|
data/lib/bundler/cli.rb
CHANGED
|
@@ -331,6 +331,7 @@ module Bundler
|
|
|
331
331
|
|
|
332
332
|
desc "info GEM [OPTIONS]", "Show information for the given gem"
|
|
333
333
|
method_option "path", :type => :boolean, :banner => "Print full path to gem"
|
|
334
|
+
method_option "version", :type => :boolean, :banner => "Print gem version"
|
|
334
335
|
def info(gem_name)
|
|
335
336
|
require_relative "cli/info"
|
|
336
337
|
Info.new(options, gem_name).run
|
|
@@ -552,7 +553,7 @@ module Bundler
|
|
|
552
553
|
method_option :version, :type => :boolean, :default => false, :aliases => "-v", :desc => "Set to show each gem version."
|
|
553
554
|
method_option :without, :type => :array, :default => [], :aliases => "-W", :banner => "GROUP[ GROUP...]", :desc => "Exclude gems that are part of the specified named group."
|
|
554
555
|
def viz
|
|
555
|
-
SharedHelpers.major_deprecation 2, "The `viz` command has been
|
|
556
|
+
SharedHelpers.major_deprecation 2, "The `viz` command has been renamed to `graph` and moved to a plugin. See https://github.com/rubygems/bundler-graph"
|
|
556
557
|
require_relative "cli/viz"
|
|
557
558
|
Viz.new(options.dup).run
|
|
558
559
|
end
|
|
@@ -575,6 +576,8 @@ module Bundler
|
|
|
575
576
|
:desc => "Generate a test directory for your library, either rspec, minitest or test-unit. Set a default with `bundle config set --global gem.test (rspec|minitest|test-unit)`."
|
|
576
577
|
method_option :ci, :type => :string, :lazy_default => Bundler.settings["gem.ci"] || "",
|
|
577
578
|
:desc => "Generate CI configuration, either GitHub Actions, Travis CI, GitLab CI or CircleCI. Set a default with `bundle config set --global gem.ci (github|travis|gitlab|circle)`"
|
|
579
|
+
method_option :linter, :type => :string, :lazy_default => Bundler.settings["gem.linter"] || "",
|
|
580
|
+
:desc => "Add a linter and code formatter, either RuboCop or Standard. Set a default with `bundle config set --global gem.linter (rubocop|standard)`"
|
|
578
581
|
method_option :github_username, :type => :string, :default => Bundler.settings["gem.github_username"], :banner => "Set your username on GitHub", :desc => "Fill in GitHub username on README so that you don't have to do it manually. Set a default with `bundle config set --global gem.github_username <your_username>`."
|
|
579
582
|
|
|
580
583
|
def gem(name)
|
|
@@ -76,11 +76,6 @@ module Bundler
|
|
|
76
76
|
|
|
77
77
|
update(local_path, remote_path, :retrying)
|
|
78
78
|
end
|
|
79
|
-
rescue Errno::EACCES
|
|
80
|
-
raise Bundler::PermissionError,
|
|
81
|
-
"Bundler does not have write access to create a temp directory " \
|
|
82
|
-
"within #{Dir.tmpdir}. Bundler must have write access to your " \
|
|
83
|
-
"systems temp directory to function properly. "
|
|
84
79
|
rescue Zlib::GzipFile::Error
|
|
85
80
|
raise Bundler::HTTPError
|
|
86
81
|
end
|
|
@@ -5,7 +5,7 @@ require "set"
|
|
|
5
5
|
|
|
6
6
|
module Bundler
|
|
7
7
|
class CompactIndexClient
|
|
8
|
-
DEBUG_MUTEX = Mutex.new
|
|
8
|
+
DEBUG_MUTEX = Thread::Mutex.new
|
|
9
9
|
def self.debug
|
|
10
10
|
return unless ENV["DEBUG_COMPACT_INDEX"]
|
|
11
11
|
DEBUG_MUTEX.synchronize { warn("[#{self}] #{yield}") }
|
|
@@ -25,7 +25,7 @@ module Bundler
|
|
|
25
25
|
@endpoints = Set.new
|
|
26
26
|
@info_checksums_by_name = {}
|
|
27
27
|
@parsed_checksums = false
|
|
28
|
-
@mutex = Mutex.new
|
|
28
|
+
@mutex = Thread::Mutex.new
|
|
29
29
|
end
|
|
30
30
|
|
|
31
31
|
def execution_mode=(block)
|