rubygems-update 3.5.5 → 3.5.10

Sign up to get free protection for your applications and to get access to all the features.
Files changed (214) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +107 -0
  3. data/Manifest.txt +84 -64
  4. data/POLICIES.md +75 -6
  5. data/bundler/CHANGELOG.md +75 -0
  6. data/bundler/lib/bundler/build_metadata.rb +2 -2
  7. data/bundler/lib/bundler/cli/binstubs.rb +1 -1
  8. data/bundler/lib/bundler/cli/gem.rb +1 -1
  9. data/bundler/lib/bundler/cli/lock.rb +5 -4
  10. data/bundler/lib/bundler/cli/plugin.rb +3 -2
  11. data/bundler/lib/bundler/cli.rb +7 -24
  12. data/bundler/lib/bundler/definition.rb +111 -56
  13. data/bundler/lib/bundler/dependency.rb +2 -1
  14. data/bundler/lib/bundler/dsl.rb +16 -1
  15. data/bundler/lib/bundler/environment_preserver.rb +5 -23
  16. data/bundler/lib/bundler/fetcher/downloader.rb +1 -1
  17. data/bundler/lib/bundler/fetcher.rb +2 -2
  18. data/bundler/lib/bundler/gem_version_promoter.rb +42 -38
  19. data/bundler/lib/bundler/injector.rb +3 -2
  20. data/bundler/lib/bundler/installer.rb +2 -2
  21. data/bundler/lib/bundler/man/bundle-add.1 +1 -1
  22. data/bundler/lib/bundler/man/bundle-binstubs.1 +1 -1
  23. data/bundler/lib/bundler/man/bundle-cache.1 +1 -1
  24. data/bundler/lib/bundler/man/bundle-check.1 +3 -1
  25. data/bundler/lib/bundler/man/bundle-check.1.ronn +3 -0
  26. data/bundler/lib/bundler/man/bundle-clean.1 +1 -1
  27. data/bundler/lib/bundler/man/bundle-config.1 +1 -3
  28. data/bundler/lib/bundler/man/bundle-config.1.ronn +0 -3
  29. data/bundler/lib/bundler/man/bundle-console.1 +1 -1
  30. data/bundler/lib/bundler/man/bundle-doctor.1 +1 -1
  31. data/bundler/lib/bundler/man/bundle-exec.1 +1 -1
  32. data/bundler/lib/bundler/man/bundle-gem.1 +1 -1
  33. data/bundler/lib/bundler/man/bundle-help.1 +1 -1
  34. data/bundler/lib/bundler/man/bundle-info.1 +1 -1
  35. data/bundler/lib/bundler/man/bundle-init.1 +1 -1
  36. data/bundler/lib/bundler/man/bundle-inject.1 +1 -1
  37. data/bundler/lib/bundler/man/bundle-install.1 +3 -3
  38. data/bundler/lib/bundler/man/bundle-install.1.ronn +2 -2
  39. data/bundler/lib/bundler/man/bundle-list.1 +1 -1
  40. data/bundler/lib/bundler/man/bundle-lock.1 +1 -1
  41. data/bundler/lib/bundler/man/bundle-open.1 +1 -1
  42. data/bundler/lib/bundler/man/bundle-outdated.1 +1 -1
  43. data/bundler/lib/bundler/man/bundle-platform.1 +1 -1
  44. data/bundler/lib/bundler/man/bundle-plugin.1 +7 -4
  45. data/bundler/lib/bundler/man/bundle-plugin.1.ronn +7 -3
  46. data/bundler/lib/bundler/man/bundle-pristine.1 +1 -1
  47. data/bundler/lib/bundler/man/bundle-remove.1 +1 -1
  48. data/bundler/lib/bundler/man/bundle-show.1 +1 -1
  49. data/bundler/lib/bundler/man/bundle-update.1 +1 -1
  50. data/bundler/lib/bundler/man/bundle-version.1 +1 -1
  51. data/bundler/lib/bundler/man/bundle-viz.1 +1 -1
  52. data/bundler/lib/bundler/man/bundle.1 +1 -1
  53. data/bundler/lib/bundler/man/gemfile.5 +3 -3
  54. data/bundler/lib/bundler/man/gemfile.5.ronn +2 -2
  55. data/bundler/lib/bundler/mirror.rb +3 -3
  56. data/bundler/lib/bundler/plugin/api/source.rb +2 -2
  57. data/bundler/lib/bundler/plugin/installer/path.rb +18 -0
  58. data/bundler/lib/bundler/plugin/installer.rb +36 -16
  59. data/bundler/lib/bundler/plugin/source_list.rb +4 -4
  60. data/bundler/lib/bundler/resolver/candidate.rb +1 -1
  61. data/bundler/lib/bundler/resolver.rb +54 -24
  62. data/bundler/lib/bundler/rubygems_ext.rb +12 -0
  63. data/bundler/lib/bundler/runtime.rb +1 -1
  64. data/bundler/lib/bundler/self_manager.rb +1 -1
  65. data/bundler/lib/bundler/settings.rb +14 -12
  66. data/bundler/lib/bundler/setup.rb +3 -0
  67. data/bundler/lib/bundler/source/git/git_proxy.rb +1 -1
  68. data/bundler/lib/bundler/source/git.rb +1 -1
  69. data/bundler/lib/bundler/source/rubygems/remote.rb +1 -1
  70. data/bundler/lib/bundler/source/rubygems.rb +7 -20
  71. data/bundler/lib/bundler/source_list.rb +17 -4
  72. data/bundler/lib/bundler/spec_set.rb +1 -1
  73. data/bundler/lib/bundler/templates/newgem/newgem.gemspec.tt +4 -3
  74. data/bundler/lib/bundler/templates/newgem/rubocop.yml.tt +0 -5
  75. data/bundler/lib/bundler/uri_credentials_filter.rb +2 -2
  76. data/bundler/lib/bundler/vendor/net-http-persistent/lib/net/http/persistent.rb +22 -22
  77. data/bundler/lib/bundler/vendor/pub_grub/lib/pub_grub/static_package_source.rb +1 -0
  78. data/bundler/lib/bundler/vendored_net_http.rb +7 -3
  79. data/bundler/lib/bundler/vendored_timeout.rb +7 -3
  80. data/bundler/lib/bundler/vendored_uri.rb +18 -1
  81. data/bundler/lib/bundler/version.rb +1 -1
  82. data/bundler/lib/bundler/yaml_serializer.rb +12 -0
  83. data/bundler/lib/bundler.rb +23 -2
  84. data/lib/rubygems/command.rb +1 -1
  85. data/lib/rubygems/command_manager.rb +2 -1
  86. data/lib/rubygems/commands/build_command.rb +2 -11
  87. data/lib/rubygems/commands/help_command.rb +2 -2
  88. data/lib/rubygems/commands/rdoc_command.rb +1 -8
  89. data/lib/rubygems/commands/rebuild_command.rb +264 -0
  90. data/lib/rubygems/commands/sources_command.rb +2 -2
  91. data/lib/rubygems/commands/update_command.rb +8 -9
  92. data/lib/rubygems/config_file.rb +20 -8
  93. data/lib/rubygems/defaults.rb +4 -4
  94. data/lib/rubygems/dependency.rb +2 -2
  95. data/lib/rubygems/dependency_list.rb +1 -1
  96. data/lib/rubygems/deprecate.rb +79 -77
  97. data/lib/rubygems/ext/cargo_builder.rb +1 -1
  98. data/lib/rubygems/gemcutter_utilities/webauthn_listener.rb +1 -1
  99. data/lib/rubygems/gemcutter_utilities/webauthn_poller.rb +3 -1
  100. data/lib/rubygems/gemcutter_utilities.rb +40 -23
  101. data/lib/rubygems/gemspec_helpers.rb +19 -0
  102. data/lib/rubygems/local_remote_options.rb +6 -6
  103. data/lib/rubygems/package.rb +13 -7
  104. data/lib/rubygems/remote_fetcher.rb +3 -3
  105. data/lib/rubygems/request.rb +5 -5
  106. data/lib/rubygems/request_set.rb +1 -1
  107. data/lib/rubygems/requirement.rb +5 -0
  108. data/lib/rubygems/resolver/api_set.rb +1 -1
  109. data/lib/rubygems/resolver/best_set.rb +1 -1
  110. data/lib/rubygems/resolver/spec_specification.rb +7 -0
  111. data/lib/rubygems/resolver.rb +5 -5
  112. data/lib/rubygems/s3_uri_signer.rb +3 -3
  113. data/lib/rubygems/safe_yaml.rb +10 -1
  114. data/lib/rubygems/security.rb +1 -1
  115. data/lib/rubygems/source/git.rb +2 -2
  116. data/lib/rubygems/source_list.rb +1 -1
  117. data/lib/rubygems/specification.rb +6 -6
  118. data/lib/rubygems/specification_policy.rb +15 -7
  119. data/lib/rubygems/uri.rb +6 -6
  120. data/lib/rubygems/util/licenses.rb +43 -0
  121. data/lib/rubygems/util.rb +1 -1
  122. data/lib/rubygems/vendor/molinillo/lib/molinillo/delegates/resolution_state.rb +57 -0
  123. data/lib/rubygems/{resolver → vendor}/molinillo/lib/molinillo/delegates/specification_provider.rb +11 -11
  124. data/lib/rubygems/{resolver → vendor}/molinillo/lib/molinillo/dependency_graph/action.rb +1 -1
  125. data/lib/rubygems/{resolver → vendor}/molinillo/lib/molinillo/dependency_graph/add_edge_no_circular.rb +1 -1
  126. data/lib/rubygems/{resolver → vendor}/molinillo/lib/molinillo/dependency_graph/add_vertex.rb +1 -1
  127. data/lib/rubygems/{resolver → vendor}/molinillo/lib/molinillo/dependency_graph/delete_edge.rb +1 -1
  128. data/lib/rubygems/{resolver → vendor}/molinillo/lib/molinillo/dependency_graph/detach_vertex_named.rb +1 -1
  129. data/lib/rubygems/{resolver → vendor}/molinillo/lib/molinillo/dependency_graph/log.rb +1 -1
  130. data/lib/rubygems/{resolver → vendor}/molinillo/lib/molinillo/dependency_graph/set_payload.rb +1 -1
  131. data/lib/rubygems/{resolver → vendor}/molinillo/lib/molinillo/dependency_graph/tag.rb +1 -1
  132. data/lib/rubygems/{resolver → vendor}/molinillo/lib/molinillo/dependency_graph/vertex.rb +1 -1
  133. data/lib/rubygems/{resolver → vendor}/molinillo/lib/molinillo/dependency_graph.rb +2 -2
  134. data/lib/rubygems/{resolver → vendor}/molinillo/lib/molinillo/errors.rb +1 -1
  135. data/lib/rubygems/vendor/molinillo/lib/molinillo/gem_metadata.rb +6 -0
  136. data/lib/rubygems/{resolver → vendor}/molinillo/lib/molinillo/modules/specification_provider.rb +2 -2
  137. data/lib/rubygems/{resolver → vendor}/molinillo/lib/molinillo/modules/ui.rb +1 -1
  138. data/lib/rubygems/{resolver → vendor}/molinillo/lib/molinillo/resolution.rb +3 -3
  139. data/lib/rubygems/{resolver → vendor}/molinillo/lib/molinillo/resolver.rb +1 -1
  140. data/lib/rubygems/{resolver → vendor}/molinillo/lib/molinillo/state.rb +1 -1
  141. data/lib/rubygems/{resolver → vendor}/molinillo/lib/molinillo.rb +2 -2
  142. data/lib/rubygems/{net-http → vendor/net-http}/lib/net/http/generic_request.rb +9 -9
  143. data/lib/rubygems/{net-http → vendor/net-http}/lib/net/http/header.rb +2 -2
  144. data/lib/rubygems/{net-http → vendor/net-http}/lib/net/http/request.rb +3 -3
  145. data/lib/rubygems/{net-http → vendor/net-http}/lib/net/http/requests.rb +30 -30
  146. data/lib/rubygems/{net-http → vendor/net-http}/lib/net/http/response.rb +2 -2
  147. data/lib/rubygems/{net-http → vendor/net-http}/lib/net/http/responses.rb +6 -6
  148. data/lib/rubygems/{net-http → vendor/net-http}/lib/net/http/status.rb +1 -1
  149. data/lib/rubygems/{net-http → vendor/net-http}/lib/net/http.rb +15 -15
  150. data/lib/rubygems/{net-http → vendor/net-http}/lib/net/https.rb +1 -1
  151. data/lib/rubygems/vendor/optparse/lib/optparse/uri.rb +7 -0
  152. data/lib/rubygems/{optparse → vendor/optparse}/lib/optparse.rb +11 -11
  153. data/lib/rubygems/{timeout → vendor/timeout}/lib/timeout.rb +1 -1
  154. data/lib/rubygems/{tsort → vendor/tsort}/lib/tsort.rb +2 -2
  155. data/lib/rubygems/vendor/uri/.document +1 -0
  156. data/lib/rubygems/vendor/uri/LICENSE.txt +22 -0
  157. data/lib/rubygems/vendor/uri/lib/uri/common.rb +853 -0
  158. data/lib/rubygems/vendor/uri/lib/uri/file.rb +100 -0
  159. data/lib/rubygems/vendor/uri/lib/uri/ftp.rb +267 -0
  160. data/lib/rubygems/vendor/uri/lib/uri/generic.rb +1588 -0
  161. data/lib/rubygems/vendor/uri/lib/uri/http.rb +125 -0
  162. data/lib/rubygems/vendor/uri/lib/uri/https.rb +23 -0
  163. data/lib/rubygems/vendor/uri/lib/uri/ldap.rb +261 -0
  164. data/lib/rubygems/vendor/uri/lib/uri/ldaps.rb +22 -0
  165. data/lib/rubygems/vendor/uri/lib/uri/mailto.rb +293 -0
  166. data/lib/rubygems/vendor/uri/lib/uri/rfc2396_parser.rb +539 -0
  167. data/lib/rubygems/vendor/uri/lib/uri/rfc3986_parser.rb +183 -0
  168. data/lib/rubygems/vendor/uri/lib/uri/version.rb +6 -0
  169. data/lib/rubygems/vendor/uri/lib/uri/ws.rb +83 -0
  170. data/lib/rubygems/vendor/uri/lib/uri/wss.rb +23 -0
  171. data/lib/rubygems/vendor/uri/lib/uri.rb +104 -0
  172. data/lib/rubygems/vendored_molinillo.rb +3 -0
  173. data/lib/rubygems/vendored_net_http.rb +5 -0
  174. data/lib/rubygems/vendored_optparse.rb +3 -0
  175. data/lib/rubygems/vendored_timeout.rb +5 -0
  176. data/lib/rubygems/vendored_tsort.rb +3 -0
  177. data/lib/rubygems/yaml_serializer.rb +12 -0
  178. data/lib/rubygems.rb +2 -2
  179. data/rubygems-update.gemspec +7 -2
  180. metadata +90 -67
  181. data/lib/rubygems/net/http.rb +0 -3
  182. data/lib/rubygems/optparse/lib/optparse/uri.rb +0 -7
  183. data/lib/rubygems/optparse.rb +0 -3
  184. data/lib/rubygems/resolver/molinillo/lib/molinillo/delegates/resolution_state.rb +0 -57
  185. data/lib/rubygems/resolver/molinillo/lib/molinillo/gem_metadata.rb +0 -6
  186. data/lib/rubygems/resolver/molinillo.rb +0 -3
  187. data/lib/rubygems/timeout.rb +0 -3
  188. data/lib/rubygems/tsort.rb +0 -3
  189. /data/lib/rubygems/{net-http → vendor/molinillo}/.document +0 -0
  190. /data/lib/rubygems/{resolver → vendor}/molinillo/LICENSE +0 -0
  191. /data/lib/rubygems/{net-protocol → vendor/net-http}/.document +0 -0
  192. /data/lib/rubygems/{net-http → vendor/net-http}/LICENSE.txt +0 -0
  193. /data/lib/rubygems/{net-http → vendor/net-http}/lib/net/http/backward.rb +0 -0
  194. /data/lib/rubygems/{net-http → vendor/net-http}/lib/net/http/exceptions.rb +0 -0
  195. /data/lib/rubygems/{net-http → vendor/net-http}/lib/net/http/proxy_delta.rb +0 -0
  196. /data/lib/rubygems/{optparse → vendor/net-protocol}/.document +0 -0
  197. /data/lib/rubygems/{net-protocol → vendor/net-protocol}/LICENSE.txt +0 -0
  198. /data/lib/rubygems/{net-protocol → vendor/net-protocol}/lib/net/protocol.rb +0 -0
  199. /data/lib/rubygems/{resolv → vendor/optparse}/.document +0 -0
  200. /data/lib/rubygems/{optparse → vendor/optparse}/COPYING +0 -0
  201. /data/lib/rubygems/{optparse → vendor/optparse}/lib/optionparser.rb +0 -0
  202. /data/lib/rubygems/{optparse → vendor/optparse}/lib/optparse/ac.rb +0 -0
  203. /data/lib/rubygems/{optparse → vendor/optparse}/lib/optparse/date.rb +0 -0
  204. /data/lib/rubygems/{optparse → vendor/optparse}/lib/optparse/kwargs.rb +0 -0
  205. /data/lib/rubygems/{optparse → vendor/optparse}/lib/optparse/shellwords.rb +0 -0
  206. /data/lib/rubygems/{optparse → vendor/optparse}/lib/optparse/time.rb +0 -0
  207. /data/lib/rubygems/{optparse → vendor/optparse}/lib/optparse/version.rb +0 -0
  208. /data/lib/rubygems/{resolver/molinillo → vendor/resolv}/.document +0 -0
  209. /data/lib/rubygems/{resolv → vendor/resolv}/LICENSE.txt +0 -0
  210. /data/lib/rubygems/{resolv → vendor/resolv}/lib/resolv.rb +0 -0
  211. /data/lib/rubygems/{timeout → vendor/timeout}/.document +0 -0
  212. /data/lib/rubygems/{timeout → vendor/timeout}/LICENSE.txt +0 -0
  213. /data/lib/rubygems/{tsort → vendor/tsort}/.document +0 -0
  214. /data/lib/rubygems/{tsort → vendor/tsort}/LICENSE.txt +0 -0
@@ -5,6 +5,7 @@ require_relative "vendored_thor"
5
5
  module Bundler
6
6
  class CLI < Thor
7
7
  require_relative "cli/common"
8
+ require_relative "cli/install"
8
9
 
9
10
  package_name "Bundler"
10
11
 
@@ -69,7 +70,7 @@ module Bundler
69
70
  Bundler.settings.set_command_option_if_given :retry, options[:retry]
70
71
 
71
72
  current_cmd = args.last[:current_command].name
72
- auto_install if AUTO_INSTALL_CMDS.include?(current_cmd)
73
+ Bundler.auto_install if AUTO_INSTALL_CMDS.include?(current_cmd)
73
74
  rescue UnknownArgumentError => e
74
75
  raise InvalidOption, e.message
75
76
  ensure
@@ -114,6 +115,8 @@ module Bundler
114
115
  class_option "verbose", type: :boolean, desc: "Enable verbose output mode", aliases: "-V"
115
116
 
116
117
  def help(cli = nil)
118
+ cli = self.class.all_aliases[cli] if self.class.all_aliases[cli]
119
+
117
120
  case cli
118
121
  when "gemfile" then command = "gemfile"
119
122
  when nil then command = "bundle"
@@ -347,6 +350,7 @@ module Bundler
347
350
  method_option "github", type: :string
348
351
  method_option "branch", type: :string
349
352
  method_option "ref", type: :string
353
+ method_option "glob", type: :string, banner: "The location of a dependency's .gemspec, expanded within Ruby (single quotes recommended)"
350
354
  method_option "skip-install", type: :boolean, banner: "Adds gem to the Gemfile but does not install it"
351
355
  method_option "optimistic", type: :boolean, banner: "Adds optimistic declaration of version to gem"
352
356
  method_option "strict", type: :boolean, banner: "Adds strict declaration of version to gem"
@@ -620,7 +624,7 @@ module Bundler
620
624
  method_option "major", type: :boolean, banner: "If updating, prefer updating to next major version (default)"
621
625
  method_option "pre", type: :boolean, banner: "If updating, always choose the highest allowed version, regardless of prerelease status"
622
626
  method_option "strict", type: :boolean, banner: "If updating, do not allow any gem to be updated past latest --patch | --minor | --major"
623
- method_option "conservative", type: :boolean, banner: "If updating, use bundle install conservative update behavior and do not allow shared dependencies to be updated"
627
+ method_option "conservative", type: :boolean, banner: "If updating, use bundle install conservative update behavior and do not allow shared dependencies to be updated"
624
628
  method_option "bundler", type: :string, lazy_default: "> 0.a", banner: "Update the locked version of bundler"
625
629
  def lock
626
630
  require_relative "cli/lock"
@@ -682,7 +686,6 @@ module Bundler
682
686
  exec_used = args.index {|a| exec_commands.include? a }
683
687
 
684
688
  command = args.find {|a| bundler_commands.include? a }
685
- command = all_aliases[command] if all_aliases[command]
686
689
 
687
690
  if exec_used && help_used
688
691
  if exec_used + help_used == 1
@@ -735,26 +738,6 @@ module Bundler
735
738
 
736
739
  private
737
740
 
738
- # Automatically invoke `bundle install` and resume if
739
- # Bundler.settings[:auto_install] exists. This is set through config cmd
740
- # `bundle config set --global auto_install 1`.
741
- #
742
- # Note that this method `nil`s out the global Definition object, so it
743
- # should be called first, before you instantiate anything like an
744
- # `Installer` that'll keep a reference to the old one instead.
745
- def auto_install
746
- return unless Bundler.settings[:auto_install]
747
-
748
- begin
749
- Bundler.definition.specs
750
- rescue GemNotFound, GitError
751
- Bundler.ui.info "Automatically installing missing gems."
752
- Bundler.reset!
753
- invoke :install, []
754
- Bundler.reset!
755
- end
756
- end
757
-
758
741
  def current_command
759
742
  _, _, config = @_initializer
760
743
  config[:current_command]
@@ -785,7 +768,7 @@ module Bundler
785
768
  return unless SharedHelpers.md5_available?
786
769
 
787
770
  latest = Fetcher::CompactIndex.
788
- new(nil, Source::Rubygems::Remote.new(Bundler::URI("https://rubygems.org")), nil, nil).
771
+ new(nil, Source::Rubygems::Remote.new(Gem::URI("https://rubygems.org")), nil, nil).
789
772
  send(:compact_index_client).
790
773
  instance_variable_get(:@cache).
791
774
  dependencies("bundler").
@@ -92,11 +92,12 @@ module Bundler
92
92
  @platforms = @locked_platforms.dup
93
93
  @locked_bundler_version = @locked_gems.bundler_version
94
94
  @locked_ruby_version = @locked_gems.ruby_version
95
+ @originally_locked_deps = @locked_gems.dependencies
95
96
  @originally_locked_specs = SpecSet.new(@locked_gems.specs)
96
97
  @locked_checksums = @locked_gems.checksums
97
98
 
98
99
  if unlock != true
99
- @locked_deps = @locked_gems.dependencies
100
+ @locked_deps = @originally_locked_deps
100
101
  @locked_specs = @originally_locked_specs
101
102
  @locked_sources = @locked_gems.sources
102
103
  else
@@ -111,6 +112,7 @@ module Bundler
111
112
  @locked_gems = nil
112
113
  @locked_deps = {}
113
114
  @locked_specs = SpecSet.new([])
115
+ @originally_locked_deps = {}
114
116
  @originally_locked_specs = @locked_specs
115
117
  @locked_sources = []
116
118
  @locked_platforms = []
@@ -130,7 +132,7 @@ module Bundler
130
132
  @sources.merged_gem_lockfile_sections!(locked_gem_sources.first)
131
133
  end
132
134
 
133
- @unlock[:sources] ||= []
135
+ @sources_to_unlock = @unlock.delete(:sources) || []
134
136
  @unlock[:ruby] ||= if @ruby_version && locked_ruby_version_object
135
137
  @ruby_version.diff(locked_ruby_version_object)
136
138
  end
@@ -142,11 +144,13 @@ module Bundler
142
144
  @path_changes = converge_paths
143
145
  @source_changes = converge_sources
144
146
 
147
+ @explicit_unlocks = @unlock.delete(:gems) || []
148
+
145
149
  if @unlock[:conservative]
146
- @unlock[:gems] ||= @dependencies.map(&:name)
150
+ @gems_to_unlock = @explicit_unlocks.any? ? @explicit_unlocks : @dependencies.map(&:name)
147
151
  else
148
- eager_unlock = (@unlock[:gems] || []).map {|name| Dependency.new(name, ">= 0") }
149
- @unlock[:gems] = @locked_specs.for(eager_unlock, false, platforms).map(&:name).uniq
152
+ eager_unlock = @explicit_unlocks.map {|name| Dependency.new(name, ">= 0") }
153
+ @gems_to_unlock = @locked_specs.for(eager_unlock, false, platforms).map(&:name).uniq
150
154
  end
151
155
 
152
156
  @dependency_changes = converge_dependencies
@@ -225,7 +229,6 @@ module Bundler
225
229
  @resolver = nil
226
230
  @resolution_packages = nil
227
231
  @specs = nil
228
- @gem_version_promoter = nil
229
232
 
230
233
  Bundler.ui.debug "The definition is missing dependencies, failed to resolve & materialize locally (#{e})"
231
234
  true
@@ -320,38 +323,26 @@ module Bundler
320
323
  dependencies.map(&:groups).flatten.uniq
321
324
  end
322
325
 
323
- def lock(file, preserve_unknown_sections = false)
324
- return if Definition.no_lock
325
-
326
- contents = to_lock
326
+ def lock(file_or_preserve_unknown_sections = false, preserve_unknown_sections_or_unused = false)
327
+ if [true, false, nil].include?(file_or_preserve_unknown_sections)
328
+ target_lockfile = lockfile || Bundler.default_lockfile
329
+ preserve_unknown_sections = file_or_preserve_unknown_sections
330
+ else
331
+ target_lockfile = file_or_preserve_unknown_sections
332
+ preserve_unknown_sections = preserve_unknown_sections_or_unused
327
333
 
328
- # Convert to \r\n if the existing lock has them
329
- # i.e., Windows with `git config core.autocrlf=true`
330
- contents.gsub!(/\n/, "\r\n") if @lockfile_contents.match?("\r\n")
334
+ suggestion = if target_lockfile == lockfile
335
+ "To fix this warning, remove it from the `Definition#lock` call."
336
+ else
337
+ "Instead, instantiate a new definition passing `#{target_lockfile}`, and call `lock` without a file argument on that definition"
338
+ end
331
339
 
332
- if @locked_bundler_version
333
- locked_major = @locked_bundler_version.segments.first
334
- current_major = bundler_version_to_lock.segments.first
340
+ msg = "`Definition#lock` was passed a target file argument. #{suggestion}"
335
341
 
336
- updating_major = locked_major < current_major
342
+ Bundler::SharedHelpers.major_deprecation 2, msg
337
343
  end
338
344
 
339
- preserve_unknown_sections ||= !updating_major && (Bundler.frozen_bundle? || !(unlocking? || @unlocking_bundler))
340
-
341
- if file && File.exist?(file) && lockfiles_equal?(@lockfile_contents, contents, preserve_unknown_sections)
342
- return if Bundler.frozen_bundle?
343
- SharedHelpers.filesystem_access(file) { FileUtils.touch(file) }
344
- return
345
- end
346
-
347
- if Bundler.frozen_bundle?
348
- Bundler.ui.error "Cannot write a changed lockfile while frozen."
349
- return
350
- end
351
-
352
- SharedHelpers.filesystem_access(file) do |p|
353
- File.open(p, "wb") {|f| f.puts(contents) }
354
- end
345
+ write_lock(target_lockfile, preserve_unknown_sections)
355
346
  end
356
347
 
357
348
  def locked_ruby_version
@@ -518,7 +509,45 @@ module Bundler
518
509
  end
519
510
 
520
511
  def lockfile_exists?
521
- lockfile && File.exist?(lockfile)
512
+ file_exists?(lockfile)
513
+ end
514
+
515
+ def file_exists?(file)
516
+ file && File.exist?(file)
517
+ end
518
+
519
+ def write_lock(file, preserve_unknown_sections)
520
+ return if Definition.no_lock
521
+
522
+ contents = to_lock
523
+
524
+ # Convert to \r\n if the existing lock has them
525
+ # i.e., Windows with `git config core.autocrlf=true`
526
+ contents.gsub!(/\n/, "\r\n") if @lockfile_contents.match?("\r\n")
527
+
528
+ if @locked_bundler_version
529
+ locked_major = @locked_bundler_version.segments.first
530
+ current_major = bundler_version_to_lock.segments.first
531
+
532
+ updating_major = locked_major < current_major
533
+ end
534
+
535
+ preserve_unknown_sections ||= !updating_major && (Bundler.frozen_bundle? || !(unlocking? || @unlocking_bundler))
536
+
537
+ if file_exists?(file) && lockfiles_equal?(@lockfile_contents, contents, preserve_unknown_sections)
538
+ return if Bundler.frozen_bundle?
539
+ SharedHelpers.filesystem_access(file) { FileUtils.touch(file) }
540
+ return
541
+ end
542
+
543
+ if Bundler.frozen_bundle?
544
+ Bundler.ui.error "Cannot write a changed lockfile while frozen."
545
+ return
546
+ end
547
+
548
+ SharedHelpers.filesystem_access(file) do |p|
549
+ File.open(p, "wb") {|f| f.puts(contents) }
550
+ end
522
551
  end
523
552
 
524
553
  def resolver
@@ -540,8 +569,10 @@ module Bundler
540
569
  @resolution_packages ||= begin
541
570
  last_resolve = converge_locked_specs
542
571
  remove_invalid_platforms!(current_dependencies)
543
- packages = Resolver::Base.new(source_requirements, expanded_dependencies, last_resolve, @platforms, locked_specs: @originally_locked_specs, unlock: @unlock[:gems], prerelease: gem_version_promoter.pre?)
544
- additional_base_requirements_for_resolve(packages, last_resolve)
572
+ packages = Resolver::Base.new(source_requirements, expanded_dependencies, last_resolve, @platforms, locked_specs: @originally_locked_specs, unlock: @gems_to_unlock, prerelease: gem_version_promoter.pre?)
573
+ packages = additional_base_requirements_to_prevent_downgrades(packages, last_resolve)
574
+ packages = additional_base_requirements_to_force_updates(packages)
575
+ packages
545
576
  end
546
577
  end
547
578
 
@@ -645,14 +676,18 @@ module Bundler
645
676
 
646
677
  def change_reason
647
678
  if unlocking?
648
- unlock_reason = @unlock.reject {|_k, v| Array(v).empty? }.map do |k, v|
649
- if v == true
650
- k.to_s
651
- else
652
- v = Array(v)
653
- "#{k}: (#{v.join(", ")})"
654
- end
655
- end.join(", ")
679
+ unlock_targets = if @gems_to_unlock.any?
680
+ ["gems", @gems_to_unlock]
681
+ elsif @sources_to_unlock.any?
682
+ ["sources", @sources_to_unlock]
683
+ end
684
+
685
+ unlock_reason = if unlock_targets
686
+ "#{unlock_targets.first}: (#{unlock_targets.last.join(", ")})"
687
+ else
688
+ @unlock[:ruby] ? "ruby" : ""
689
+ end
690
+
656
691
  return "bundler is unlocking #{unlock_reason}"
657
692
  end
658
693
  [
@@ -707,7 +742,7 @@ module Bundler
707
742
  spec = @dependencies.find {|s| s.name == k }
708
743
  source = spec&.source
709
744
  if source&.respond_to?(:local_override!)
710
- source.unlock! if @unlock[:gems].include?(spec.name)
745
+ source.unlock! if @gems_to_unlock.include?(spec.name)
711
746
  locals << [source, source.local_override!(v)]
712
747
  end
713
748
  end
@@ -715,7 +750,7 @@ module Bundler
715
750
  sources_with_changes = locals.select do |source, changed|
716
751
  changed || specs_changed?(source)
717
752
  end.map(&:first)
718
- !sources_with_changes.each {|source| @unlock[:sources] << source.name }.empty?
753
+ !sources_with_changes.each {|source| @sources_to_unlock << source.name }.empty?
719
754
  end
720
755
 
721
756
  def check_lockfile
@@ -792,7 +827,7 @@ module Bundler
792
827
  # gem), unlock it. For git sources, this means to unlock the revision, which
793
828
  # will cause the `ref` used to be the most recent for the branch (or master) if
794
829
  # an explicit `ref` is not used.
795
- if source.respond_to?(:unlock!) && @unlock[:sources].include?(source.name)
830
+ if source.respond_to?(:unlock!) && @sources_to_unlock.include?(source.name)
796
831
  source.unlock!
797
832
  changes = true
798
833
  end
@@ -809,9 +844,7 @@ module Bundler
809
844
  dep.source = sources.get(dep.source)
810
845
  end
811
846
 
812
- next if unlocking?
813
-
814
- unless locked_dep = @locked_deps[dep.name]
847
+ unless locked_dep = @originally_locked_deps[dep.name]
815
848
  changes = true
816
849
  next
817
850
  end
@@ -838,7 +871,7 @@ module Bundler
838
871
  def converge_locked_specs
839
872
  converged = converge_specs(@locked_specs)
840
873
 
841
- resolve = SpecSet.new(converged.reject {|s| @unlock[:gems].include?(s.name) })
874
+ resolve = SpecSet.new(converged.reject {|s| @gems_to_unlock.include?(s.name) })
842
875
 
843
876
  diff = nil
844
877
 
@@ -871,7 +904,7 @@ module Bundler
871
904
 
872
905
  @specs_that_changed_sources << s if gemfile_source != lockfile_source
873
906
  deps << dep if !dep.source || lockfile_source.include?(dep.source)
874
- @unlock[:gems] << name if lockfile_source.include?(dep.source) && lockfile_source != gemfile_source
907
+ @gems_to_unlock << name if lockfile_source.include?(dep.source) && lockfile_source != gemfile_source
875
908
 
876
909
  # Replace the locked dependency's source with the equivalent source from the Gemfile
877
910
  s.source = gemfile_source
@@ -880,7 +913,7 @@ module Bundler
880
913
  s.source = default_source unless sources.get(lockfile_source)
881
914
  end
882
915
 
883
- next if @unlock[:sources].include?(s.source.name)
916
+ next if @sources_to_unlock.include?(s.source.name)
884
917
 
885
918
  # Path sources have special logic
886
919
  if s.source.instance_of?(Source::Path) || s.source.instance_of?(Source::Gemspec)
@@ -902,12 +935,12 @@ module Bundler
902
935
  else
903
936
  # If the spec is no longer in the path source, unlock it. This
904
937
  # commonly happens if the version changed in the gemspec
905
- @unlock[:gems] << name
938
+ @gems_to_unlock << name
906
939
  end
907
940
  end
908
941
 
909
942
  if dep.nil? && requested_dependencies.find {|d| name == d.name }
910
- @unlock[:gems] << s.name
943
+ @gems_to_unlock << s.name
911
944
  else
912
945
  converged << s
913
946
  end
@@ -984,7 +1017,7 @@ module Bundler
984
1017
  current == proposed
985
1018
  end
986
1019
 
987
- def additional_base_requirements_for_resolve(resolution_packages, last_resolve)
1020
+ def additional_base_requirements_to_prevent_downgrades(resolution_packages, last_resolve)
988
1021
  return resolution_packages unless @locked_gems && !sources.expired_sources?(@locked_gems.sources)
989
1022
  converge_specs(@originally_locked_specs - last_resolve).each do |locked_spec|
990
1023
  next if locked_spec.source.is_a?(Source::Path)
@@ -993,6 +1026,28 @@ module Bundler
993
1026
  resolution_packages
994
1027
  end
995
1028
 
1029
+ def additional_base_requirements_to_force_updates(resolution_packages)
1030
+ return resolution_packages if @explicit_unlocks.empty?
1031
+ full_update = dup_for_full_unlock.resolve
1032
+ @explicit_unlocks.each do |name|
1033
+ version = full_update[name].first&.version
1034
+ resolution_packages.base_requirements[name] = Gem::Requirement.new("= #{version}") if version
1035
+ end
1036
+ resolution_packages
1037
+ end
1038
+
1039
+ def dup_for_full_unlock
1040
+ unlocked_definition = self.class.new(@lockfile, @dependencies, @sources, true, @ruby_version, @optional_groups, @gemfiles)
1041
+ unlocked_definition.resolution_mode = { "local" => !@remote }
1042
+ unlocked_definition.setup_sources_for_resolve
1043
+ unlocked_definition.gem_version_promoter.tap do |gvp|
1044
+ gvp.level = gem_version_promoter.level
1045
+ gvp.strict = gem_version_promoter.strict
1046
+ gvp.pre = gem_version_promoter.pre
1047
+ end
1048
+ unlocked_definition
1049
+ end
1050
+
996
1051
  def remove_invalid_platforms!(dependencies)
997
1052
  return if Bundler.frozen_bundle?
998
1053
 
@@ -7,7 +7,7 @@ require_relative "rubygems_ext"
7
7
  module Bundler
8
8
  class Dependency < Gem::Dependency
9
9
  attr_reader :autorequire
10
- attr_reader :groups, :platforms, :gemfile, :path, :git, :github, :branch, :ref
10
+ attr_reader :groups, :platforms, :gemfile, :path, :git, :github, :branch, :ref, :glob
11
11
 
12
12
  ALL_RUBY_VERSIONS = (18..27).to_a.concat((30..34).to_a).freeze
13
13
  PLATFORM_MAP = {
@@ -39,6 +39,7 @@ module Bundler
39
39
  @github = options["github"]
40
40
  @branch = options["branch"]
41
41
  @ref = options["ref"]
42
+ @glob = options["glob"]
42
43
  @platforms = Array(options["platforms"])
43
44
  @env = options["env"]
44
45
  @should_include = options.fetch("should_include", true)
@@ -19,6 +19,7 @@ module Bundler
19
19
  platform platforms type source install_if gemfile force_ruby_platform].freeze
20
20
 
21
21
  GITHUB_PULL_REQUEST_URL = %r{\Ahttps://github\.com/([A-Za-z0-9_\-\.]+/[A-Za-z0-9_\-\.]+)/pull/(\d+)\z}
22
+ GITLAB_MERGE_REQUEST_URL = %r{\Ahttps://gitlab\.com/([A-Za-z0-9_\-\./]+)/-/merge_requests/(\d+)\z}
22
23
 
23
24
  attr_reader :gemspecs, :gemfile
24
25
  attr_accessor :dependencies
@@ -46,7 +47,7 @@ module Bundler
46
47
  @gemfile = expanded_gemfile_path
47
48
  @gemfiles << expanded_gemfile_path
48
49
  contents ||= Bundler.read_file(@gemfile.to_s)
49
- instance_eval(contents, gemfile.to_s, 1)
50
+ instance_eval(contents, @gemfile.to_s, 1)
50
51
  rescue Exception => e # rubocop:disable Lint/RescueException
51
52
  message = "There was an error " \
52
53
  "#{e.is_a?(GemfileEvalError) ? "evaluating" : "parsing"} " \
@@ -308,6 +309,20 @@ module Bundler
308
309
  repo_name ||= user_name
309
310
  "https://#{user_name}@bitbucket.org/#{user_name}/#{repo_name}.git"
310
311
  end
312
+
313
+ git_source(:gitlab) do |repo_name|
314
+ if repo_name =~ GITLAB_MERGE_REQUEST_URL
315
+ {
316
+ "git" => "https://gitlab.com/#{$1}.git",
317
+ "branch" => nil,
318
+ "ref" => "refs/merge-requests/#{$2}/head",
319
+ "tag" => nil,
320
+ }
321
+ else
322
+ repo_name = "#{repo_name}/#{repo_name}" unless repo_name.include?("/")
323
+ "https://gitlab.com/#{repo_name}.git"
324
+ end
325
+ end
311
326
  end
312
327
 
313
328
  def with_source(source)
@@ -19,14 +19,7 @@ module Bundler
19
19
  BUNDLER_PREFIX = "BUNDLER_ORIG_"
20
20
 
21
21
  def self.from_env
22
- new(env_to_hash(ENV), BUNDLER_KEYS)
23
- end
24
-
25
- def self.env_to_hash(env)
26
- to_hash = env.to_hash
27
- return to_hash unless Gem.win_platform?
28
-
29
- to_hash.each_with_object({}) {|(k,v), a| a[k.upcase] = v }
22
+ new(ENV.to_hash, BUNDLER_KEYS)
30
23
  end
31
24
 
32
25
  # @param env [Hash]
@@ -39,18 +32,7 @@ module Bundler
39
32
 
40
33
  # Replaces `ENV` with the bundler environment variables backed up
41
34
  def replace_with_backup
42
- unless Gem.win_platform?
43
- ENV.replace(backup)
44
- return
45
- end
46
-
47
- # Fallback logic for Windows below to workaround
48
- # https://bugs.ruby-lang.org/issues/16798. Can be dropped once all
49
- # supported rubies include the fix for that.
50
-
51
- ENV.clear
52
-
53
- backup.each {|k, v| ENV[k] = v }
35
+ ENV.replace(backup)
54
36
  end
55
37
 
56
38
  # @return [Hash]
@@ -58,9 +40,9 @@ module Bundler
58
40
  env = @original.clone
59
41
  @keys.each do |key|
60
42
  value = env[key]
61
- if !value.nil? && !value.empty?
43
+ if !value.nil?
62
44
  env[@prefix + key] ||= value
63
- elsif value.nil?
45
+ else
64
46
  env[@prefix + key] ||= INTENTIONALLY_NIL
65
47
  end
66
48
  end
@@ -72,7 +54,7 @@ module Bundler
72
54
  env = @original.clone
73
55
  @keys.each do |key|
74
56
  value_original = env[@prefix + key]
75
- next if value_original.nil? || value_original.empty?
57
+ next if value_original.nil?
76
58
  if value_original == INTENTIONALLY_NIL
77
59
  env.delete(key)
78
60
  else
@@ -23,7 +23,7 @@ module Bundler
23
23
  when Gem::Net::HTTPSuccess, Gem::Net::HTTPNotModified
24
24
  response
25
25
  when Gem::Net::HTTPRedirection
26
- new_uri = Bundler::URI.parse(response["location"])
26
+ new_uri = Gem::URI.parse(response["location"])
27
27
  if new_uri.host == uri.host
28
28
  new_uri.user = uri.user
29
29
  new_uri.password = uri.password
@@ -111,7 +111,7 @@ module Bundler
111
111
  spec -= [nil, "ruby", ""]
112
112
  spec_file_name = "#{spec.join "-"}.gemspec"
113
113
 
114
- uri = Bundler::URI.parse("#{remote_uri}#{Gem::MARSHAL_SPEC_DIR}#{spec_file_name}.rz")
114
+ uri = Gem::URI.parse("#{remote_uri}#{Gem::MARSHAL_SPEC_DIR}#{spec_file_name}.rz")
115
115
  spec = if uri.scheme == "file"
116
116
  path = Gem::Util.correct_for_windows_path(uri.path)
117
117
  Bundler.safe_load_marshal Bundler.rubygems.inflate(Gem.read_binary(path))
@@ -255,7 +255,7 @@ module Bundler
255
255
 
256
256
  con = Gem::Net::HTTP::Persistent.new name: "bundler", proxy: :ENV
257
257
  if gem_proxy = Gem.configuration[:http_proxy]
258
- con.proxy = Bundler::URI.parse(gem_proxy) if gem_proxy != :no_proxy
258
+ con.proxy = Gem::URI.parse(gem_proxy) if gem_proxy != :no_proxy
259
259
  end
260
260
 
261
261
  if remote_uri.scheme == "https"
@@ -45,17 +45,37 @@ module Bundler
45
45
 
46
46
  # Given a Resolver::Package and an Array of Specifications of available
47
47
  # versions for a gem, this method will return the Array of Specifications
48
- # sorted (and possibly truncated if strict is true) in an order to give
49
- # preference to the current level (:major, :minor or :patch) when resolution
50
- # is deciding what versions best resolve all dependencies in the bundle.
48
+ # sorted in an order to give preference to the current level (:major, :minor
49
+ # or :patch) when resolution is deciding what versions best resolve all
50
+ # dependencies in the bundle.
51
51
  # @param package [Resolver::Package] The package being resolved.
52
52
  # @param specs [Specification] An array of Specifications for the package.
53
- # @return [Specification] A new instance of the Specification Array sorted and
54
- # possibly filtered.
53
+ # @return [Specification] A new instance of the Specification Array sorted.
55
54
  def sort_versions(package, specs)
56
- specs = filter_dep_specs(specs, package) if strict
55
+ locked_version = package.locked_version
57
56
 
58
- sort_dep_specs(specs, package)
57
+ result = specs.sort do |a, b|
58
+ unless package.prerelease_specified? || pre?
59
+ a_pre = a.prerelease?
60
+ b_pre = b.prerelease?
61
+
62
+ next 1 if a_pre && !b_pre
63
+ next -1 if b_pre && !a_pre
64
+ end
65
+
66
+ if major? || locked_version.nil?
67
+ b <=> a
68
+ elsif either_version_older_than_locked?(a, b, locked_version)
69
+ b <=> a
70
+ elsif segments_do_not_match?(a, b, :major)
71
+ a <=> b
72
+ elsif !minor? && segments_do_not_match?(a, b, :minor)
73
+ a <=> b
74
+ else
75
+ b <=> a
76
+ end
77
+ end
78
+ post_sort(result, package.unlock?, locked_version)
59
79
  end
60
80
 
61
81
  # @return [bool] Convenience method for testing value of level variable.
@@ -73,9 +93,18 @@ module Bundler
73
93
  pre == true
74
94
  end
75
95
 
76
- private
96
+ # Given a Resolver::Package and an Array of Specifications of available
97
+ # versions for a gem, this method will truncate the Array if strict
98
+ # is true. That means filtering out downgrades from the version currently
99
+ # locked, and filtering out upgrades that go past the selected level (major,
100
+ # minor, or patch).
101
+ # @param package [Resolver::Package] The package being resolved.
102
+ # @param specs [Specification] An array of Specifications for the package.
103
+ # @return [Specification] A new instance of the Specification Array
104
+ # truncated.
105
+ def filter_versions(package, specs)
106
+ return specs unless strict
77
107
 
78
- def filter_dep_specs(specs, package)
79
108
  locked_version = package.locked_version
80
109
  return specs if locked_version.nil? || major?
81
110
 
@@ -89,32 +118,7 @@ module Bundler
89
118
  end
90
119
  end
91
120
 
92
- def sort_dep_specs(specs, package)
93
- locked_version = package.locked_version
94
-
95
- result = specs.sort do |a, b|
96
- unless package.prerelease_specified? || pre?
97
- a_pre = a.prerelease?
98
- b_pre = b.prerelease?
99
-
100
- next -1 if a_pre && !b_pre
101
- next 1 if b_pre && !a_pre
102
- end
103
-
104
- if major? || locked_version.nil?
105
- a <=> b
106
- elsif either_version_older_than_locked?(a, b, locked_version)
107
- a <=> b
108
- elsif segments_do_not_match?(a, b, :major)
109
- b <=> a
110
- elsif !minor? && segments_do_not_match?(a, b, :minor)
111
- b <=> a
112
- else
113
- a <=> b
114
- end
115
- end
116
- post_sort(result, package.unlock?, locked_version)
117
- end
121
+ private
118
122
 
119
123
  def either_version_older_than_locked?(a, b, locked_version)
120
124
  a.version < locked_version || b.version < locked_version
@@ -133,13 +137,13 @@ module Bundler
133
137
  if unlock || locked_version.nil?
134
138
  result
135
139
  else
136
- move_version_to_end(result, locked_version)
140
+ move_version_to_beginning(result, locked_version)
137
141
  end
138
142
  end
139
143
 
140
- def move_version_to_end(result, version)
144
+ def move_version_to_beginning(result, version)
141
145
  move, keep = result.partition {|s| s.version.to_s == version.to_s }
142
- keep.concat(move)
146
+ move.concat(keep)
143
147
  end
144
148
  end
145
149
  end
@@ -50,7 +50,7 @@ module Bundler
50
50
  append_to(gemfile_path, build_gem_lines(@options[:conservative_versioning])) if @deps.any?
51
51
 
52
52
  # since we resolved successfully, write out the lockfile
53
- @definition.lock(Bundler.default_lockfile)
53
+ @definition.lock
54
54
 
55
55
  # invalidate the cached Bundler.definition
56
56
  Bundler.reset_paths!
@@ -120,9 +120,10 @@ module Bundler
120
120
  github = ", :github => \"#{d.github}\"" unless d.github.nil?
121
121
  branch = ", :branch => \"#{d.branch}\"" unless d.branch.nil?
122
122
  ref = ", :ref => \"#{d.ref}\"" unless d.ref.nil?
123
+ glob = ", :glob => \"#{d.glob}\"" unless d.glob.nil?
123
124
  require_path = ", :require => #{convert_autorequire(d.autorequire)}" unless d.autorequire.nil?
124
125
 
125
- %(gem #{name}#{requirement}#{group}#{source}#{path}#{git}#{github}#{branch}#{ref}#{require_path})
126
+ %(gem #{name}#{requirement}#{group}#{source}#{path}#{git}#{github}#{branch}#{ref}#{glob}#{require_path})
126
127
  end.join("\n")
127
128
  end
128
129