rubygems-update 4.1.0.beta1 → 4.1.0.beta3

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.
Files changed (100) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +152 -8
  3. data/Manifest.txt +1 -3
  4. data/SECURITY.md +10 -1
  5. data/lib/bundler/build_metadata.rb +2 -2
  6. data/lib/bundler/cli/common.rb +4 -0
  7. data/lib/bundler/cli/doctor/ssl.rb +4 -8
  8. data/lib/bundler/cli/info.rb +1 -1
  9. data/lib/bundler/cli/lock.rb +19 -4
  10. data/lib/bundler/cli/open.rb +7 -1
  11. data/lib/bundler/cli/outdated.rb +8 -10
  12. data/lib/bundler/cli/platform.rb +15 -1
  13. data/lib/bundler/cli/show.rb +5 -1
  14. data/lib/bundler/cli/update.rb +1 -1
  15. data/lib/bundler/cli.rb +22 -7
  16. data/lib/bundler/constants.rb +1 -1
  17. data/lib/bundler/definition.rb +102 -16
  18. data/lib/bundler/dsl.rb +76 -5
  19. data/lib/bundler/fetcher/downloader.rb +14 -4
  20. data/lib/bundler/fetcher.rb +4 -1
  21. data/lib/bundler/gem_helper.rb +1 -1
  22. data/lib/bundler/installer/parallel_installer.rb +2 -1
  23. data/lib/bundler/installer.rb +5 -1
  24. data/lib/bundler/lazy_specification.rb +1 -1
  25. data/lib/bundler/lockfile_generator.rb +6 -0
  26. data/lib/bundler/lockfile_parser.rb +18 -2
  27. data/lib/bundler/man/bundle-info.1 +4 -1
  28. data/lib/bundler/man/bundle-info.1.ronn +4 -0
  29. data/lib/bundler/man/bundle-lock.1 +2 -2
  30. data/lib/bundler/man/bundle-lock.1.ronn +4 -3
  31. data/lib/bundler/man/bundle-open.1 +4 -1
  32. data/lib/bundler/man/bundle-open.1.ronn +4 -1
  33. data/lib/bundler/man/bundle-outdated.1 +1 -1
  34. data/lib/bundler/man/bundle-outdated.1.ronn +1 -1
  35. data/lib/bundler/man/bundle-show.1 +4 -1
  36. data/lib/bundler/man/bundle-show.1.ronn +4 -0
  37. data/lib/bundler/man/bundle-update.1 +3 -3
  38. data/lib/bundler/man/bundle-update.1.ronn +5 -3
  39. data/lib/bundler/man/gemfile.5 +43 -2
  40. data/lib/bundler/man/gemfile.5.ronn +69 -4
  41. data/lib/bundler/match_platform.rb +12 -3
  42. data/lib/bundler/materialization.rb +3 -1
  43. data/lib/bundler/override.rb +83 -2
  44. data/lib/bundler/resolver.rb +28 -4
  45. data/lib/bundler/rubygems_ext.rb +15 -4
  46. data/lib/bundler/self_manager.rb +15 -9
  47. data/lib/bundler/settings.rb +10 -26
  48. data/lib/bundler/source/git/git_proxy.rb +39 -2
  49. data/lib/bundler/source/git.rb +34 -7
  50. data/lib/bundler/source/rubygems.rb +2 -2
  51. data/lib/bundler/source/rubygems_aggregate.rb +1 -1
  52. data/lib/bundler/source_map.rb +7 -3
  53. data/lib/bundler/spec_set.rb +8 -4
  54. data/lib/bundler/templates/newgem/ext/newgem/Cargo.toml.tt +1 -1
  55. data/lib/bundler/vendor/fileutils/lib/fileutils.rb +54 -29
  56. data/lib/bundler/version.rb +1 -1
  57. data/lib/bundler.rb +1 -3
  58. data/lib/rubygems/command_manager.rb +1 -5
  59. data/lib/rubygems/commands/build_command.rb +34 -3
  60. data/lib/rubygems/commands/exec_command.rb +3 -0
  61. data/lib/rubygems/commands/update_command.rb +2 -2
  62. data/lib/rubygems/compact_index_client/http_fetcher.rb +5 -3
  63. data/lib/rubygems/compact_index_client/parser.rb +1 -0
  64. data/lib/rubygems/content_address.rb +17 -14
  65. data/lib/rubygems/deprecate.rb +2 -2
  66. data/lib/rubygems/ext/builder.rb +17 -6
  67. data/lib/rubygems/gemcutter_utilities/webauthn_listener.rb +9 -0
  68. data/lib/rubygems/installer.rb +4 -22
  69. data/lib/rubygems/package.rb +60 -46
  70. data/lib/rubygems/package_task.rb +75 -6
  71. data/lib/rubygems/psych_tree.rb +0 -4
  72. data/lib/rubygems/remote_fetcher.rb +12 -6
  73. data/lib/rubygems/request/connection_pools.rb +4 -2
  74. data/lib/rubygems/resolver/api_set.rb +1 -1
  75. data/lib/rubygems/safe_marshal/visitors/to_ruby.rb +8 -22
  76. data/lib/rubygems/security.rb +16 -10
  77. data/lib/rubygems/source/git.rb +3 -1
  78. data/lib/rubygems/specification.rb +14 -1
  79. data/lib/rubygems/specification_policy.rb +12 -10
  80. data/lib/rubygems/uninstaller.rb +15 -2
  81. data/lib/rubygems/uri.rb +2 -2
  82. data/lib/rubygems/user_interaction.rb +6 -9
  83. data/lib/rubygems/util/atomic_file_writer.rb +4 -2
  84. data/lib/rubygems/vendor/net-http/lib/net/http/generic_request.rb +10 -1
  85. data/lib/rubygems/vendor/net-http/lib/net/http/header.rb +56 -15
  86. data/lib/rubygems/vendor/net-http/lib/net/http/request.rb +1 -0
  87. data/lib/rubygems/vendor/net-http/lib/net/http/requests.rb +59 -24
  88. data/lib/rubygems/vendor/net-http/lib/net/http/response.rb +40 -15
  89. data/lib/rubygems/vendor/net-http/lib/net/http.rb +97 -16
  90. data/lib/rubygems/vendor/net-protocol/lib/net/protocol.rb +95 -26
  91. data/lib/rubygems/vendor/uri/lib/uri/common.rb +1 -1
  92. data/lib/rubygems/vendor/uri/lib/uri/generic.rb +15 -3
  93. data/lib/rubygems/vendor/uri/lib/uri/version.rb +1 -1
  94. data/lib/rubygems/win_platform.rb +0 -3
  95. data/lib/rubygems/yaml_serializer.rb +131 -103
  96. data/lib/rubygems.rb +49 -25
  97. metadata +656 -657
  98. data/lib/rubygems/vendor/net-protocol/LICENSE.txt +0 -22
  99. data/lib/rubygems/vendor/resolv/lib/resolv.rb +0 -3508
  100. /data/lib/rubygems/vendor/{resolv → net-protocol}/COPYING +0 -0
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b352c4644037755a5e766ee276d2356a72562c64003a787e5ead57ffdd2f6f59
4
- data.tar.gz: cc343e5d3bd5a9d3cab8eea31cef6425181ab659ba0d1ea881e84e6f7dca4e76
3
+ metadata.gz: 6318a5162408d17e02ca7534ba15f8701fe7eeeeaf7d891f4331588d0e595472
4
+ data.tar.gz: c044abf170bb96482454ed885860c11aa96cda0618cdaac5177009bdbb1d814d
5
5
  SHA512:
6
- metadata.gz: c891896e6322726cb21068e0a6ebcf1b9c68150eb8713a6e046ce7e2e8f8dafbb9e432d010d9b3f945c282f07c82ea45a149ab153d6dae4b0524234135172d60
7
- data.tar.gz: 4ec266e81774d02b685d030902415a2edd83379bd3299d3259f6f4e10c26e3096a2e09c448c85b58a07953f6c6c71058f5e7fd50434f8e65dabb60d3f006b28a
6
+ metadata.gz: 3c0e7401e36950ef3563213d1489dacccf2cdabf370c63bdb789a0ac0f0bd68987d3ac558dcb9054bbd9dc6ab0003853878d4563f43a43fb995d77d6ecfd6ddb
7
+ data.tar.gz: 0677d5d8ec93ba1e7d6698c7b480d5f496cc2d42a37aea380e981133da66ef3b49bece38b90aab61425a30c5b7126e6f2354eea48614b508ec6ac72e6225e856
data/CHANGELOG.md CHANGED
@@ -2,6 +2,150 @@
2
2
 
3
3
  Bundler's changelog before 4.0.0, when it was versioned separately from RubyGems, is in [doc/CHANGELOG-bundler-2.x.md](https://github.com/ruby/rubygems/blob/master/doc/CHANGELOG-bundler-2.x.md).
4
4
 
5
+ ## 4.1.0.beta3 / 2026-10-28
6
+
7
+ ### RubyGems
8
+
9
+ #### Enhancements:
10
+
11
+ * Installs bundler 4.1.0.beta3 as a default gem.
12
+
13
+ #### Bug fixes:
14
+
15
+ * Skip executable removal gracefully when the bin directory is missing. Pull request [#9963](https://github.com/ruby/rubygems/pull/9963) by Evan Li and Hiroshi SHIBATA
16
+ * Fix file locks letting multiple processes in when lock files are removed. Pull request [#9930](https://github.com/ruby/rubygems/pull/9930) by Richard Janita and Hiroshi SHIBATA
17
+ * Turn off echo before printing the password prompt. Pull request [#9969](https://github.com/ruby/rubygems/pull/9969) by Mike Dalessio
18
+
19
+ ### Bundler
20
+
21
+ Changes already released in 4.0.x are not repeated here.
22
+
23
+ #### Features:
24
+
25
+ * Rename the `from:` and `to:` keys of `override` to `in:` and `with:`. Pull request [#9979](https://github.com/ruby/rubygems/pull/9979) by Hiroshi SHIBATA
26
+ * Record overrides in Gemfile.lock (`OVERRIDES` section). Pull request [#9958](https://github.com/ruby/rubygems/pull/9958) by Ufuk Kayserilioglu
27
+
28
+ #### Bug fixes:
29
+
30
+ * Make `Bundler::Source::Rubygems#hash` agree with `eql?`. Pull request [#9983](https://github.com/ruby/rubygems/pull/9983) by Hiroshi SHIBATA
31
+ * Add checksums after platform changes in `bundle lock`. Pull request [#9960](https://github.com/ruby/rubygems/pull/9960) by Farid Zakaria
32
+ * Apply BUNDLE_RETRY to lazy gemspec downloads. Pull request [#9868](https://github.com/ruby/rubygems/pull/9868) by Islam Elsayed
33
+ * Fix file locks letting multiple processes in when lock files are removed. Pull request [#9930](https://github.com/ruby/rubygems/pull/9930) by Richard Janita and Hiroshi SHIBATA
34
+ * Preload git sources that share a cache one after another. Pull request [#9951](https://github.com/ruby/rubygems/pull/9951) by Shai
35
+
36
+ ## 4.0.23 / 2026-10-14
37
+
38
+ ### RubyGems
39
+
40
+ #### Enhancements:
41
+
42
+ * Update vendored gems to latest versions. Pull request [#9948](https://github.com/ruby/rubygems/pull/9948) by Hiroshi SHIBATA
43
+ * Drop setuid, setgid and sticky bits when extracting gems. Pull request [#9929](https://github.com/ruby/rubygems/pull/9929) by Hiroshi SHIBATA
44
+ * Improve handling of paths with invalid Windows characters. Pull request [#9276](https://github.com/ruby/rubygems/pull/9276) by Said Kaldybaev and Hiroshi SHIBATA
45
+ * Installs bundler 4.0.23 as a default gem.
46
+
47
+ ### Bundler
48
+
49
+ #### Enhancements:
50
+
51
+ * Update vendored gems to latest versions. Pull request [#9948](https://github.com/ruby/rubygems/pull/9948) by Hiroshi SHIBATA
52
+
53
+ #### Bug fixes:
54
+
55
+ * Stop retrying a 416 response to a request without Range. Pull request [#9938](https://github.com/ruby/rubygems/pull/9938) by Hiroshi SHIBATA
56
+ * Respect Gemfile lockfile in `bundle lock`. Pull request [#9661](https://github.com/ruby/rubygems/pull/9661) by David Stosik and Hiroshi SHIBATA
57
+
58
+ ## 4.1.0.beta2 / 2026-10-08
59
+
60
+ ### RubyGems
61
+
62
+ Changes already released in 4.0.x are not repeated here.
63
+
64
+ #### Features:
65
+
66
+ * Support content addressable gems in `Gem::PackageTask`. Pull request [#9897](https://github.com/ruby/rubygems/pull/9897) by Harriet Oughton, Gira Chawda and Jenny Shen
67
+ * Add `--content-addressable` to `gem build` and make `--ruby-abi` only set the Ruby ABI. Pull request [#9906](https://github.com/ruby/rubygems/pull/9906) by Harriet Oughton
68
+
69
+ #### Enhancements:
70
+
71
+ * Drop setuid, setgid and sticky bits when extracting gems. Pull request [#9929](https://github.com/ruby/rubygems/pull/9929) by Hiroshi SHIBATA
72
+ * Improve handling of paths with invalid Windows characters. Pull request [#9276](https://github.com/ruby/rubygems/pull/9276) by Said Kaldybaev and Hiroshi SHIBATA
73
+ * Installs bundler 4.1.0.beta2 as a default gem.
74
+
75
+ #### Breaking changes:
76
+
77
+ * Build a platform gem with `gem build --platform` for the local platform. Pull request [#9873](https://github.com/ruby/rubygems/pull/9873) by Hiroshi SHIBATA
78
+ * Fix `gem update --user-install` updating gems outside the user directory. Pull request [#9872](https://github.com/ruby/rubygems/pull/9872) by Hiroshi SHIBATA
79
+
80
+ ### Bundler
81
+
82
+ Changes already released in 4.0.x are not repeated here.
83
+
84
+ #### Features:
85
+
86
+ * Let override drop or replace one dependency of a gem. Pull request [#9935](https://github.com/ruby/rubygems/pull/9935) by Hiroshi SHIBATA
87
+ * Add `sparse_checkout` option to git source. Pull request [#9295](https://github.com/ruby/rubygems/pull/9295) by Ian Ker-Seymer and Hiroshi SHIBATA
88
+ * Implement `--exact-match` Flag for `bundle info` / `show` / `open`. Pull request [#9489](https://github.com/ruby/rubygems/pull/9489) by Harriet Oughton
89
+
90
+ #### Bug fixes:
91
+
92
+ * Respect Gemfile lockfile in `bundle lock`. Pull request [#9661](https://github.com/ruby/rubygems/pull/9661) by David Stosik and Hiroshi SHIBATA
93
+
94
+ ## 4.0.22 / 2026-09-30
95
+
96
+ ### RubyGems
97
+
98
+ #### Enhancements:
99
+
100
+ * Add --source option to gem exec command. Pull request [#9765](https://github.com/ruby/rubygems/pull/9765) by Akshay Birajdar
101
+ * Keep credentials on redirects only within the same origin. Pull request [#9909](https://github.com/ruby/rubygems/pull/9909) by Hiroshi SHIBATA
102
+ * Validate the version field in Gem::Installer#verify_spec. Pull request [#9890](https://github.com/ruby/rubygems/pull/9890) by Hiroshi SHIBATA
103
+ * Installs bundler 4.0.22 as a default gem.
104
+
105
+ #### Bug fixes:
106
+
107
+ * Remove the build_info file on uninstall and stop gem build from logging unknown extensions. Pull request [#9894](https://github.com/ruby/rubygems/pull/9894) by Hiroshi SHIBATA
108
+
109
+ ### Bundler
110
+
111
+ #### Enhancements:
112
+
113
+ * Report the effective platform in `bundle platform`. Pull request [#9898](https://github.com/ruby/rubygems/pull/9898) by Islam Elsayed
114
+ * Keep credentials on redirects only within the same origin. Pull request [#9909](https://github.com/ruby/rubygems/pull/9909) by Hiroshi SHIBATA
115
+ * Update Magnus version in Rust extension gem template. Pull request [#9904](https://github.com/ruby/rubygems/pull/9904) by Mat Sadler and Hiroshi SHIBATA
116
+
117
+ #### Bug fixes:
118
+
119
+ * Stop `Bundler.bin_path` creating the directory it reports. Pull request [#9887](https://github.com/ruby/rubygems/pull/9887) by Islam Elsayed and Hiroshi SHIBATA
120
+ * Look up `bundler-<command>` executables only in PATH. Pull request [#9874](https://github.com/ruby/rubygems/pull/9874) by Hiroshi SHIBATA
121
+
122
+ #### Documentation:
123
+
124
+ * Describe `--major` as preferring the latest major version. Pull request [#9891](https://github.com/ruby/rubygems/pull/9891) by Hiroshi SHIBATA
125
+
126
+ ## 4.0.21 / 2026-09-16
127
+
128
+ ### RubyGems
129
+
130
+ #### Enhancements:
131
+
132
+ * Stop vendoring resolv for two regexps. Pull request [#9877](https://github.com/ruby/rubygems/pull/9877) by Hiroshi SHIBATA
133
+ * Normalize absolute symlink targets during gem extraction. Pull request [#9860](https://github.com/ruby/rubygems/pull/9860) by Hiroshi SHIBATA
134
+ * Installs bundler 4.0.21 as a default gem.
135
+
136
+ ### Bundler
137
+
138
+ #### Enhancements:
139
+
140
+ * Don't update bundler to a prerelease unless asked for one. Pull request [#9869](https://github.com/ruby/rubygems/pull/9869) by Hiroshi SHIBATA
141
+ * Reject Bundler redirects that downgrade https to http. Pull request [#9859](https://github.com/ruby/rubygems/pull/9859) by Hiroshi SHIBATA
142
+
143
+ #### Bug fixes:
144
+
145
+ * Support `safe.bareRepository=explicit` in git sources. Pull request [#9876](https://github.com/ruby/rubygems/pull/9876) by Hiroshi SHIBATA
146
+ * Stop resolving locally for empty CHECKSUMS entries. Pull request [#9862](https://github.com/ruby/rubygems/pull/9862) by Hiroshi SHIBATA
147
+ * Expand the git source gemspec path before the chdir. Pull request [#9845](https://github.com/ruby/rubygems/pull/9845) by Hiroshi SHIBATA
148
+
5
149
  ## 4.1.0.beta1 / 2026-09-09
6
150
 
7
151
  ### RubyGems
@@ -10,14 +154,14 @@ Changes already released in 4.0.x are not repeated here.
10
154
 
11
155
  #### Features:
12
156
 
13
- * Add content addressable gems support. Pull request [#9773](https://github.com/ruby/rubygems/pull/9773) by Jenny Shen
157
+ * Add content addressable gems support. Pull request [#9773](https://github.com/ruby/rubygems/pull/9773) by Jenny Shen, Harriet Oughton and Gira Chawda
14
158
  * Let the gem and bundle cooldown settings cover each other. Pull request [#9852](https://github.com/ruby/rubygems/pull/9852) by Hiroshi SHIBATA
15
- * Rubygems: Add PQC ML-DSA support for cryptographically signed gems workflow. Pull request [#9697](https://github.com/ruby/rubygems/pull/9697) by Jun Aruga
159
+ * Rubygems: Add PQC ML-DSA support for cryptographically signed gems workflow. Pull request [#9697](https://github.com/ruby/rubygems/pull/9697) by Jun Aruga, Kazuki Yamaguchi and Hiroshi SHIBATA
16
160
  * Preserve non-UTF-8 legacy gem metadata. Pull request [#9835](https://github.com/ruby/rubygems/pull/9835) by Stanislav (Stas) Katkov
17
161
  * Add an opt-in OS credential store for gem and bundler credentials. Pull request [#9671](https://github.com/ruby/rubygems/pull/9671) by Hiroshi SHIBATA
18
162
  * Add --cooldown to gem install, update and outdated. Pull request [#9734](https://github.com/ruby/rubygems/pull/9734) by Hiroshi SHIBATA
19
163
  * Adopt the compact index for gem commands. Pull request [#9606](https://github.com/ruby/rubygems/pull/9606) by Hiroshi SHIBATA
20
- * Replace Molinillo with PubGrub for dependency resolution. Pull request [#9402](https://github.com/ruby/rubygems/pull/9402) by Matt Larraz
164
+ * Replace Molinillo with PubGrub for dependency resolution. Pull request [#9402](https://github.com/ruby/rubygems/pull/9402) by Matt Larraz and Colby Swandale
21
165
  * Replace the rubygems-specific lockfile parser with Bundler's parser. Pull request [#9564](https://github.com/ruby/rubygems/pull/9564) by Hiroshi SHIBATA
22
166
  * Remove pessimistic versioning in gem command output. Pull request [#9550](https://github.com/ruby/rubygems/pull/9550) by Jeremy Evans
23
167
  * Change Gem::Version#approximate_recommendation to be optimistic. Pull request [#9537](https://github.com/ruby/rubygems/pull/9537) by Jeremy Evans
@@ -52,7 +196,7 @@ Changes already released in 4.0.x are not repeated here.
52
196
 
53
197
  #### Features:
54
198
 
55
- * Add content addressable gems support. Pull request [#9773](https://github.com/ruby/rubygems/pull/9773) by Jenny Shen
199
+ * Add content addressable gems support. Pull request [#9773](https://github.com/ruby/rubygems/pull/9773) by Jenny Shen, Harriet Oughton and Gira Chawda
56
200
  * Let the gem and bundle cooldown settings cover each other. Pull request [#9852](https://github.com/ruby/rubygems/pull/9852) by Hiroshi SHIBATA
57
201
  * Add a `prune` setting to drop rebuildable install artifacts. Pull request [#9815](https://github.com/ruby/rubygems/pull/9815) by Hiroshi SHIBATA
58
202
  * Add an opt-in OS credential store for gem and bundler credentials. Pull request [#9671](https://github.com/ruby/rubygems/pull/9671) by Hiroshi SHIBATA
@@ -63,8 +207,8 @@ Changes already released in 4.0.x are not repeated here.
63
207
  * Reuse RubyGems' vendored SecureRandom in Bundler. Pull request [#9651](https://github.com/ruby/rubygems/pull/9651) by Hiroshi SHIBATA
64
208
  * Reuse RubyGems' vendored URI in Bundler. Pull request [#9650](https://github.com/ruby/rubygems/pull/9650) by Hiroshi SHIBATA
65
209
  * Fix two issues by including the ruby platform variants in the lock file. Pull request [#9556](https://github.com/ruby/rubygems/pull/9556) by Randy Stauner
66
- * Fix plugin installation from gemfile. Pull request [#6957](https://github.com/ruby/rubygems/pull/6957) by Cody Cutrer
67
- * Add plugin hooks for Gemfile evaluation and source fetching. Pull request [#9488](https://github.com/ruby/rubygems/pull/9488) by Hiroshi SHIBATA
210
+ * Fix plugin installation from gemfile. Pull request [#6957](https://github.com/ruby/rubygems/pull/6957) by Cody Cutrer, Diogo Fernandes and Hiroshi SHIBATA
211
+ * Add plugin hooks for Gemfile evaluation and source fetching. Pull request [#9488](https://github.com/ruby/rubygems/pull/9488) by Hiroshi SHIBATA, Cody Cutrer and Marv
68
212
  * Use optimistic version constraints in bundle gem output. Pull request [#9533](https://github.com/ruby/rubygems/pull/9533) by Jeremy Evans
69
213
  * Extend Gemfile `override` DSL with `:all` target and metadata fields (Phase 2). Pull request [#9530](https://github.com/ruby/rubygems/pull/9530) by Hiroshi SHIBATA
70
214
  * Switch bundle add to use optimistic versioning by default. Pull request [#9526](https://github.com/ruby/rubygems/pull/9526) by Jeremy Evans
@@ -72,7 +216,7 @@ Changes already released in 4.0.x are not repeated here.
72
216
  * Add `--no-build-extension` and `--no-install-plugin` options to gem install. Pull request [#9473](https://github.com/ruby/rubygems/pull/9473) by Hiroshi SHIBATA
73
217
  * Include detailed dependencies when gemfile and lockfile are conflicts. Pull request [#9332](https://github.com/ruby/rubygems/pull/9332) by Hiroshi SHIBATA
74
218
  * Implement relative path handling for plugin paths. Pull request [#9299](https://github.com/ruby/rubygems/pull/9299) by Hiroshi SHIBATA
75
- * Bundler/inline: perform installation from a forked child. Pull request [#7941](https://github.com/ruby/rubygems/pull/7941) by Jean byroot Boussier
219
+ * Bundler/inline: perform installation from a forked child. Pull request [#7941](https://github.com/ruby/rubygems/pull/7941) by Jean Boussier and Hiroshi SHIBATA
76
220
  * Add global gem cache shared by RubyGems and Bundler. Pull request [#9230](https://github.com/ruby/rubygems/pull/9230) by Anthony Panozzo
77
221
  * Update custom errors with Exception#full_message. Pull request [#8488](https://github.com/ruby/rubygems/pull/8488) by neimadTL
78
222
 
@@ -92,7 +236,7 @@ Changes already released in 4.0.x are not repeated here.
92
236
  #### Breaking changes:
93
237
 
94
238
  * Remove external tool version checks from `bundle env`. Pull request [#9593](https://github.com/ruby/rubygems/pull/9593) by Hiroshi SHIBATA
95
- * Bundler: ignore patchlevel kwarg in ruby DSL. Pull request [#6023](https://github.com/ruby/rubygems/pull/6023) by Takuya N
239
+ * Bundler: ignore patchlevel kwarg in ruby DSL. Pull request [#6023](https://github.com/ruby/rubygems/pull/6023) by Takuya N and Hiroshi SHIBATA
96
240
  * Unify RubyGems and Bundler documentation. Pull request [#9237](https://github.com/ruby/rubygems/pull/9237) by Hiroshi SHIBATA
97
241
 
98
242
  #### Deprecations:
data/Manifest.txt CHANGED
@@ -503,7 +503,7 @@ lib/rubygems/vendor/net-http/lib/net/http/response.rb
503
503
  lib/rubygems/vendor/net-http/lib/net/http/responses.rb
504
504
  lib/rubygems/vendor/net-http/lib/net/http/status.rb
505
505
  lib/rubygems/vendor/net-http/lib/net/https.rb
506
- lib/rubygems/vendor/net-protocol/LICENSE.txt
506
+ lib/rubygems/vendor/net-protocol/COPYING
507
507
  lib/rubygems/vendor/net-protocol/lib/net/protocol.rb
508
508
  lib/rubygems/vendor/optparse/COPYING
509
509
  lib/rubygems/vendor/optparse/lib/optionparser.rb
@@ -533,8 +533,6 @@ lib/rubygems/vendor/pub_grub/lib/pub_grub/version_constraint.rb
533
533
  lib/rubygems/vendor/pub_grub/lib/pub_grub/version_range.rb
534
534
  lib/rubygems/vendor/pub_grub/lib/pub_grub/version_solver.rb
535
535
  lib/rubygems/vendor/pub_grub/lib/pub_grub/version_union.rb
536
- lib/rubygems/vendor/resolv/COPYING
537
- lib/rubygems/vendor/resolv/lib/resolv.rb
538
536
  lib/rubygems/vendor/securerandom/COPYING
539
537
  lib/rubygems/vendor/securerandom/lib/securerandom.rb
540
538
  lib/rubygems/vendor/timeout/COPYING
data/SECURITY.md CHANGED
@@ -2,6 +2,15 @@
2
2
 
3
3
  We deeply appreciate any effort to discover and disclose security vulnerabilities responsibly.
4
4
 
5
- For any security bug or issue with the RubyGems client or RubyGems.org service, please email security@rubygems.org with details about the problem or submit a report using [HackerOne](https://hackerone.com/rubygems).
5
+ For any security bug or issue with the RubyGems client, Bundler, or RubyGems.org service, please email security@rubygems.org with details about the problem or submit a report using [HackerOne](https://hackerone.com/rubygems). A malicious or compromised gem published on RubyGems.org can be reported the same way.
6
6
 
7
7
  For additional information about RubyGems security, please see https://rubygems.org/pages/security.
8
+
9
+ ## Out of scope for RubyGems and Bundler
10
+
11
+ The following are not treated as vulnerabilities. A technically correct report may still be fixed in public as a regular bug or hardening change.
12
+
13
+ - Code you chose to run, whether a gem you install or the `Gemfile` of a repository you run `bundle` in. A gem can ship a native extension whose build runs arbitrary code as you, and a `Gemfile` is Ruby code, so anything a crafted gem or repository does within your privileges, such as writing or deleting files or path traversal through gem metadata, adds no capability, whether or not the gem declares extensions.
14
+ - A gem source or mirror you chose to trust. Reports that assume the configured source is malicious or compromised are out of scope, and so is gem metadata that rubygems.org rejects at push time, since it can only arrive from a local file or a gem server you chose to trust.
15
+ - Your own environment and settings. This covers attacks that require write access to files RubyGems or Bundler already load on your behalf, such as plugins, `.gemrc` or `.bundle/config`, and behavior after you explicitly disable a protection such as TLS certificate verification.
16
+ - Issues already fixed on the `master` branch. Please check it before reporting.
@@ -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 = "2026-09-09".freeze
8
- @git_commit_sha = "98e4d8083a7".freeze
7
+ @built_at = "2026-10-28".freeze
8
+ @git_commit_sha = "cd7536a".freeze
9
9
  # end ivars
10
10
 
11
11
  # A hash representation of the build metadata.
@@ -122,6 +122,10 @@ module Bundler
122
122
  raise GemNotFound, gem_not_found_message(name, Bundler.definition.dependencies)
123
123
  end
124
124
 
125
+ def self.select_spec_with_match_type(name, options)
126
+ select_spec(name, options["exact-match"] ? nil : :regex_match)
127
+ end
128
+
125
129
  def self.default_gem_spec(name)
126
130
  gem_spec = Gem::Specification.find_all_by_name(name).last
127
131
  gem_spec if gem_spec&.default_gem?
@@ -124,14 +124,10 @@ module Bundler
124
124
  ctx = OpenSSL::SSL::SSLContext.new
125
125
  supported = true
126
126
 
127
- if ctx.respond_to?(:min_version=)
128
- begin
129
- ctx.min_version = ctx.max_version = OpenSSL::SSL::TLS1_2_VERSION
130
- rescue OpenSSL::SSL::SSLError, NameError
131
- supported = false
132
- end
133
- else
134
- supported = OpenSSL::SSL::SSLContext::METHODS.include?(:TLSv1_2) # rubocop:disable Naming/VariableNumber
127
+ begin
128
+ ctx.min_version = ctx.max_version = OpenSSL::SSL::TLS1_2_VERSION
129
+ rescue OpenSSL::SSL::SSLError, NameError
130
+ supported = false
135
131
  end
136
132
 
137
133
  Bundler.ui.warn(<<~EOM) unless supported
@@ -26,7 +26,7 @@ module Bundler
26
26
  private
27
27
 
28
28
  def spec_for_gem(name)
29
- Bundler::CLI::Common.select_spec(name, :regex_match)
29
+ Bundler::CLI::Common.select_spec_with_match_type(name, options)
30
30
  end
31
31
 
32
32
  def print_gem_version(spec)
@@ -42,7 +42,6 @@ module Bundler
42
42
 
43
43
  Bundler.settings.temporary(frozen: false) do
44
44
  definition = Bundler.definition(update, Bundler.default_lockfile)
45
- definition.add_checksums if options["add-checksums"]
46
45
 
47
46
  Bundler::CLI::Common.configure_gem_version_promoter(definition, options) if options[:update]
48
47
 
@@ -64,6 +63,11 @@ module Bundler
64
63
  raise InvalidOption, "Removing all platforms from the bundle is not allowed"
65
64
  end
66
65
 
66
+ # Adding checksums resolves the bundle to fetch them, so it has to
67
+ # run after every platform change above has been recorded, or the
68
+ # new platforms are listed in the lockfile without their specs.
69
+ definition.add_checksums if options["add-checksums"]
70
+
67
71
  definition.remotely! unless options[:local]
68
72
 
69
73
  if options["normalize-platforms"]
@@ -74,10 +78,21 @@ module Bundler
74
78
  puts definition.to_lock
75
79
  else
76
80
  file = options[:lockfile]
77
- file = file ? Pathname.new(file).expand_path : Bundler.default_lockfile
81
+ file = if file
82
+ Pathname.new(file).expand_path
83
+ elsif ENV["BUNDLE_LOCKFILE"].to_s.empty?
84
+ definition.lockfile
85
+ else
86
+ # BUNDLE_LOCKFILE outranks the lockfile method in the Gemfile, see gemfile(5)
87
+ Bundler.default_lockfile
88
+ end
78
89
 
79
- puts "Writing lockfile to #{file}"
80
- definition.write_lock(file, false)
90
+ if file
91
+ puts "Writing lockfile to #{file}"
92
+ definition.write_lock(file, false)
93
+ else
94
+ Bundler.ui.warn "Not writing a lockfile because the Gemfile sets `lockfile false`"
95
+ end
81
96
  end
82
97
 
83
98
  Bundler::CLI::Common.output_cooldown_skipped_summary(definition)
@@ -13,7 +13,7 @@ module Bundler
13
13
  raise InvalidOption, "Cannot specify `--path` option without a value" if !@path.nil? && @path.empty?
14
14
  editor = [ENV["BUNDLER_EDITOR"], ENV["VISUAL"], ENV["EDITOR"]].find {|e| !e.nil? && !e.empty? }
15
15
  return Bundler.ui.info("To open a bundled gem, set $EDITOR or $BUNDLER_EDITOR") unless editor
16
- return unless spec = Bundler::CLI::Common.select_spec(name, :regex_match)
16
+ return unless spec = spec_for_gem(name)
17
17
  if spec.default_gem?
18
18
  Bundler.ui.info "Unable to open #{name} because it's a default gem, so the directory it would normally be installed to does not exist."
19
19
  else
@@ -35,5 +35,11 @@ module Bundler
35
35
  require "shellwords"
36
36
  Shellwords.split(editor)
37
37
  end
38
+
39
+ private
40
+
41
+ def spec_for_gem(name)
42
+ Bundler::CLI::Common.select_spec_with_match_type(name, options)
43
+ end
38
44
  end
39
45
  end
@@ -90,7 +90,9 @@ module Bundler
90
90
  dependency = current_dependencies[current_spec.name]
91
91
  groups = ""
92
92
  if dependency && !options[:parseable]
93
- groups = dependency.groups.join(", ")
93
+ groups = dependency.groups
94
+ groups = groups.sort if options_include_groups
95
+ groups = groups.join(", ")
94
96
  end
95
97
 
96
98
  outdated_gems << {
@@ -101,13 +103,11 @@ module Bundler
101
103
  }
102
104
  end
103
105
 
104
- relevant_outdated_gems = if options_include_groups
105
- outdated_gems.group_by {|g| g[:groups] }.sort.flat_map do |groups, gems|
106
- contains_group = groups.split(", ").include?(options[:group])
107
- next unless options[:groups] || contains_group
108
-
109
- gems
110
- end.compact
106
+ relevant_outdated_gems = if options[:groups]
107
+ without_groups, with_groups = outdated_gems.partition {|g| g[:groups].empty? }
108
+ with_groups.group_by {|g| g[:groups] }.sort.flat_map(&:last) + without_groups
109
+ elsif options_include_groups
110
+ outdated_gems.select {|g| g[:groups].split(", ").include?(options[:group]) }
111
111
  else
112
112
  outdated_gems
113
113
  end
@@ -333,8 +333,6 @@ module Bundler
333
333
 
334
334
  Bundler.ui.info justify(header, column_sizes)
335
335
 
336
- data.sort_by! {|row| row[0] }
337
-
338
336
  data.each do |row|
339
337
  Bundler.ui.info justify(row, column_sizes)
340
338
  end
@@ -25,7 +25,7 @@ module Bundler
25
25
  else
26
26
  platforms = Bundler.definition.platforms.map {|p| "* #{p}" }
27
27
 
28
- output << "Your platform is: #{Gem::Platform.local}"
28
+ output << platform_info
29
29
  output << "Your app has gems that work on these platforms:\n#{platforms.join("\n")}"
30
30
 
31
31
  if ruby_version
@@ -44,5 +44,19 @@ module Bundler
44
44
 
45
45
  Bundler.ui.info output.join("\n\n")
46
46
  end
47
+
48
+ private
49
+
50
+ def platform_info
51
+ info = "Your platform is: #{Gem::Platform.local}"
52
+ return info if Bundler.local_platform == Gem::Platform.local
53
+
54
+ info + "\nHowever, your effective platform is: #{Bundler.local_platform} " \
55
+ "(because force_ruby_platform is #{force_ruby_platform_origin})"
56
+ end
57
+
58
+ def force_ruby_platform_origin
59
+ Bundler.settings.pretty_values_for(:force_ruby_platform).first.sub(/\ASet /, "set ")
60
+ end
47
61
  end
48
62
  end
@@ -20,7 +20,7 @@ module Bundler
20
20
  if gem_name == "bundler"
21
21
  path = File.expand_path("../../..", __dir__)
22
22
  else
23
- spec = Bundler::CLI::Common.select_spec(gem_name, :regex_match)
23
+ spec = spec_for_gem(gem_name)
24
24
  return unless spec
25
25
  path = spec.full_gem_path
26
26
  unless File.directory?(path)
@@ -55,6 +55,10 @@ module Bundler
55
55
 
56
56
  private
57
57
 
58
+ def spec_for_gem(name)
59
+ Bundler::CLI::Common.select_spec_with_match_type(name, options)
60
+ end
61
+
58
62
  def fetch_latest_specs
59
63
  definition = Bundler.definition(true)
60
64
  Bundler.ui.info "Fetching remote specs for outdated check...\n\n"
@@ -13,7 +13,7 @@ module Bundler
13
13
 
14
14
  update_bundler = options[:bundler]
15
15
 
16
- Bundler.self_manager.update_bundler_and_restart_with_it_if_needed(update_bundler) if update_bundler
16
+ Bundler.self_manager.update_bundler_and_restart_with_it_if_needed(update_bundler, pre: options[:pre]) if update_bundler
17
17
 
18
18
  sources = Array(options[:source])
19
19
  groups = Array(options[:group]).map(&:to_sym)
data/lib/bundler/cli.rb CHANGED
@@ -177,7 +177,7 @@ module Bundler
177
177
  else
178
178
  puts File.read("#{man_path}/#{File.basename(man_page)}.ronn")
179
179
  end
180
- elsif command_path = Bundler.which("bundler-#{cli}")
180
+ elsif command_path = self.class.bundler_command_path(cli)
181
181
  Kernel.exec(command_path, "--help")
182
182
  else
183
183
  super
@@ -189,11 +189,23 @@ module Bundler
189
189
  return Bundler::Plugin.exec_command(command, ARGV[1..-1])
190
190
  end
191
191
 
192
- return super unless command_path = Bundler.which("bundler-#{command}")
192
+ return super unless command_path = bundler_command_path(command)
193
193
 
194
194
  Kernel.exec(command_path, *ARGV[1..-1])
195
195
  end
196
196
 
197
+ # Only PATH is searched, unlike Bundler.which, which also finds a file in
198
+ # the current directory and returns a bare name that Kernel.exec cannot run.
199
+ def self.bundler_command_path(command)
200
+ ENV.fetch("PATH", "").split(File::PATH_SEPARATOR).each do |path|
201
+ path = path[1..-2] if path.start_with?('"') && path.end_with?('"')
202
+ command_path = Bundler.find_executable(File.expand_path("bundler-#{command}", path))
203
+ return command_path if command_path
204
+ end
205
+
206
+ nil
207
+ end
208
+
197
209
  desc "init [OPTIONS]", "Generates a Gemfile into the current working directory"
198
210
  long_desc <<-D
199
211
  Init generates a default Gemfile in the current working directory. When adding a
@@ -319,10 +331,10 @@ module Bundler
319
331
  method_option "source", type: :array, banner: "Update a specific source (and all gems associated with it)"
320
332
  method_option "force", type: :boolean, aliases: "--redownload", banner: "Force reinstalling every gem, even if already installed"
321
333
  method_option "ruby", type: :boolean, banner: "Update ruby specified in Gemfile.lock"
322
- method_option "bundler", type: :string, lazy_default: "> 0.a", banner: "Update the locked version of bundler"
334
+ method_option "bundler", type: :string, lazy_default: ">= #{Bundler::VERSION}", banner: "Update the locked version of bundler"
323
335
  method_option "patch", type: :boolean, banner: "Prefer updating only to next patch version"
324
336
  method_option "minor", type: :boolean, banner: "Prefer updating only to next minor version"
325
- method_option "major", type: :boolean, banner: "Prefer updating to next major version (default)"
337
+ method_option "major", type: :boolean, banner: "Prefer updating to latest major version (default)"
326
338
  method_option "pre", type: :boolean, banner: "Always choose the highest allowed version when updating gems, regardless of prerelease status"
327
339
  method_option "strict", type: :boolean, banner: "Do not allow any gem to be updated past latest --patch | --minor | --major"
328
340
  method_option "conservative", type: :boolean, banner: "Use bundle install conservative update behavior and do not allow shared dependencies to be updated."
@@ -342,6 +354,7 @@ module Bundler
342
354
  D
343
355
  method_option "paths", type: :boolean, banner: "List the paths of all gems that are required by your Gemfile."
344
356
  method_option "outdated", type: :boolean, banner: "Show verbose output including whether gems are outdated (removed)."
357
+ method_option "exact-match", type: :boolean, banner: "Only match gems whose names exactly match the given name"
345
358
  def show(gem_name = nil)
346
359
  if ARGV.include?("--outdated")
347
360
  removed_message = "the `--outdated` flag to `bundle show` has been removed in favor of `bundle show --verbose`"
@@ -367,6 +380,7 @@ module Bundler
367
380
  desc "info GEM [OPTIONS]", "Show information for the given gem"
368
381
  method_option "path", type: :boolean, banner: "Print full path to gem"
369
382
  method_option "version", type: :boolean, banner: "Print gem version"
383
+ method_option "exact-match", type: :boolean, banner: "Only match gems whose names exactly match the given name"
370
384
  def info(gem_name)
371
385
  require_relative "cli/info"
372
386
  Info.new(options, gem_name).run
@@ -434,7 +448,7 @@ module Bundler
434
448
  method_option "filter-strict", type: :boolean, aliases: "--strict", banner: "Only list newer versions allowed by your Gemfile requirements"
435
449
  method_option "update-strict", type: :boolean, banner: "Strict conservative resolution, do not allow any gem to be updated past latest --patch | --minor | --major"
436
450
  method_option "minor", type: :boolean, banner: "Prefer updating only to next minor version"
437
- method_option "major", type: :boolean, banner: "Prefer updating to next major version (default)"
451
+ method_option "major", type: :boolean, banner: "Prefer updating to latest major version (default)"
438
452
  method_option "patch", type: :boolean, banner: "Prefer updating only to next patch version"
439
453
  method_option "filter-major", type: :boolean, banner: "Only list major newer versions"
440
454
  method_option "filter-minor", type: :boolean, banner: "Only list minor newer versions"
@@ -530,6 +544,7 @@ module Bundler
530
544
 
531
545
  desc "open GEM", "Opens the source directory of the given bundled gem"
532
546
  method_option "path", type: :string, lazy_default: "", banner: "Open relative path of the gem source."
547
+ method_option "exact-match", type: :boolean, banner: "Only match gems whose names exactly match the given name"
533
548
  def open(name)
534
549
  require_relative "cli/open"
535
550
  Open.new(options, name).run
@@ -640,11 +655,11 @@ module Bundler
640
655
  method_option "normalize-platforms", type: :boolean, default: false, banner: "Normalize lockfile platforms"
641
656
  method_option "patch", type: :boolean, banner: "If updating, prefer updating only to next patch version"
642
657
  method_option "minor", type: :boolean, banner: "If updating, prefer updating only to next minor version"
643
- method_option "major", type: :boolean, banner: "If updating, prefer updating to next major version (default)"
658
+ method_option "major", type: :boolean, banner: "If updating, prefer updating to latest major version (default)"
644
659
  method_option "pre", type: :boolean, banner: "If updating, always choose the highest allowed version, regardless of prerelease status"
645
660
  method_option "strict", type: :boolean, banner: "If updating, do not allow any gem to be updated past latest --patch | --minor | --major"
646
661
  method_option "conservative", type: :boolean, banner: "If updating, use bundle install conservative update behavior and do not allow shared dependencies to be updated"
647
- method_option "bundler", type: :string, lazy_default: "> 0.a", banner: "Update the locked version of bundler"
662
+ method_option "bundler", type: :string, lazy_default: ">= #{Bundler::VERSION}", banner: "Update the locked version of bundler"
648
663
  method_option "cooldown", type: :numeric, banner: "Only consider gem versions published at least N days ago. Use 0 to disable."
649
664
  def lock
650
665
  require_relative "cli/lock"
@@ -3,7 +3,7 @@
3
3
  require "rbconfig"
4
4
 
5
5
  module Bundler
6
- WINDOWS = RbConfig::CONFIG["host_os"] =~ /(msdos|mswin|djgpp|mingw)/
6
+ WINDOWS = RbConfig::CONFIG["host_os"] =~ /(mswin|mingw)/
7
7
  deprecate_constant :WINDOWS
8
8
 
9
9
  FREEBSD = RbConfig::CONFIG["host_os"].to_s.include?("bsd")