ruby/tool/bundler
David Rodríguez 053caa313b
Fix `gem exec rails new foo` failing on Ruby 3.2
The default version of securerandom (0.2.2) gets activated by RubyGems,
but does not match Rails requirements (>= 0.3), leading to an error like
this:

```
$ gem exec rails new repro
/Users/deivid/Code/rubygems/rubygems/lib/rubygems/specification.rb:2246:in `raise_if_conflicts': Unable to activate activesupport-7.2.1, because securerandom-0.2.2 conflicts with securerandom (>= 0.3) (Gem::ConflictError)
	from /Users/deivid/Code/rubygems/rubygems/lib/rubygems/specification.rb:1383:in `activate'
	from /Users/deivid/Code/rubygems/rubygems/lib/rubygems/specification.rb:1421:in `block in activate_dependencies'
	from /Users/deivid/Code/rubygems/rubygems/lib/rubygems/specification.rb:1403:in `each'
	from /Users/deivid/Code/rubygems/rubygems/lib/rubygems/specification.rb:1403:in `activate_dependencies'
	from /Users/deivid/Code/rubygems/rubygems/lib/rubygems/specification.rb:1385:in `activate'
	from /Users/deivid/Code/rubygems/rubygems/lib/rubygems/core_ext/kernel_gem.rb:62:in `block in gem'
	from /Users/deivid/Code/rubygems/rubygems/lib/rubygems/core_ext/kernel_gem.rb:62:in `synchronize'
	from /Users/deivid/Code/rubygems/rubygems/lib/rubygems/core_ext/kernel_gem.rb:62:in `gem'
	from /Users/deivid/Code/rubygems/rubygems/lib/rubygems/commands/exec_command.rb:193:in `activate!'
	from /Users/deivid/Code/rubygems/rubygems/lib/rubygems/commands/exec_command.rb:73:in `execute'
	from /Users/deivid/Code/rubygems/rubygems/lib/rubygems/command.rb:326:in `invoke_with_build_args'
	from /Users/deivid/Code/rubygems/rubygems/lib/rubygems/command_manager.rb:255:in `invoke_command'
	from /Users/deivid/Code/rubygems/rubygems/lib/rubygems/command_manager.rb:194:in `process_args'
	from /Users/deivid/Code/rubygems/rubygems/lib/rubygems/command_manager.rb:152:in `run'
	from /Users/deivid/Code/rubygems/rubygems/lib/rubygems/gem_runner.rb:56:in `run'
	from /Users/deivid/code/rubygems/rubygems/exe/gem:12:in `<main>'
```

Vendoring our own securerandom fixes the issue since that way we avoid
activating the gem internally.
2024-09-03 10:49:13 +09:00
..
dev_gems.rb Update turbo_tests to 2.2.3 or higher 2024-04-19 08:32:01 +09:00
rubocop_gems.rb [PRISM] Revert incorrectly merged gemfile 2024-07-11 14:25:54 -04:00
standard_gems.rb Merge RubyGems-3.4.0 and Bundler-2.4.0 2022-12-24 16:57:07 +09:00
test_gems.rb Inject base64 for basic auth examples of bundler 2024-01-17 08:28:31 +09:00
vendor_gems.rb Fix `gem exec rails new foo` failing on Ruby 3.2 2024-09-03 10:49:13 +09:00