<feed xmlns='http://www.w3.org/2005/Atom'>
<title>ruby.git/lib/bundler/shared_helpers.rb, branch v3_3_11</title>
<subtitle>The Ruby Programming Language</subtitle>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/'/>
<entry>
<title>Update RubyGems 3.5.16 and Bundler 2.5.16 for Ruby 3.3 (#11252)</title>
<updated>2024-07-30T16:05:54+00:00</updated>
<author>
<name>Hiroshi SHIBATA</name>
<email>hsbt@ruby-lang.org</email>
</author>
<published>2024-07-30T16:05:54+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=f85c7deacc25738bd83ba182370c283ba82b61d4'/>
<id>f85c7deacc25738bd83ba182370c283ba82b61d4</id>
<content type='text'>
* Merge RubyGems-3.5.12 and Bundler-2.5.12

* Merge RubyGems-3.5.13 and Bundler-2.5.13

* Merge RubyGems-3.5.14 and Bundler-2.5.14

* Merge RubyGems-3.5.15 and Bundler-2.5.15

* Merge RubyGems-3.5.16 and Bundler-2.5.16</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* Merge RubyGems-3.5.12 and Bundler-2.5.12

* Merge RubyGems-3.5.13 and Bundler-2.5.13

* Merge RubyGems-3.5.14 and Bundler-2.5.14

* Merge RubyGems-3.5.15 and Bundler-2.5.15

* Merge RubyGems-3.5.16 and Bundler-2.5.16</pre>
</div>
</content>
</entry>
<entry>
<title>Merge RubyGems 3.5.11 and Bundler 2.5.11 for Ruby 3.3 (#10870)</title>
<updated>2024-06-05T04:36:46+00:00</updated>
<author>
<name>Hiroshi SHIBATA</name>
<email>hsbt@ruby-lang.org</email>
</author>
<published>2024-06-05T04:36:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=06f470ce66be24f82d3720dd2bb08b18b16753ac'/>
<id>06f470ce66be24f82d3720dd2bb08b18b16753ac</id>
<content type='text'>
Co-authored-by: Nobuyoshi Nakada &lt;nobu@ruby-lang.org&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Co-authored-by: Nobuyoshi Nakada &lt;nobu@ruby-lang.org&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>[rubygems/rubygems] Improve install advice when some gems are not found</title>
<updated>2023-12-14T12:22:48+00:00</updated>
<author>
<name>David Rodríguez</name>
<email>deivid.rodriguez@riseup.net</email>
</author>
<published>2023-12-13T13:42:21+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=45b511433d652c46d5652ab295367f41341697af'/>
<id>45b511433d652c46d5652ab295367f41341697af</id>
<content type='text'>
This problem is quite specific to our dev environment, but I guess the
fix could be handy for other situations.

After merging a change to treat default gems as regular gems, I get this
when trying to run `rubocop` on our repo:

```
$ bin/rubocop  --only Performance/RegexpMatch
Could not find json-2.6.3 in locally installed gems
Run `bundle install --gemfile /Users/deivid/code/rubygems/rubygems/tool/bundler/lint_gems.rb` to install missing gems.
```

However, when running the suggested command, nothing changes and I still
get the same error:

```
$ bundle install --gemfile /Users/deivid/code/rubygems/rubygems/tool/bundler/lint_gems.rb
Using ast 2.4.2
Using bundler 2.4.10
Using json 2.6.3
Using parallel 1.23.0
Using racc 1.7.1
Using parser 3.2.2.3
Using rainbow 3.1.1
Using regexp_parser 2.8.1
Using rexml 3.2.5
Using rubocop-ast 1.29.0
Using ruby-progressbar 1.13.0
Using unicode-display_width 2.4.2
Using rubocop 1.52.1
Using rubocop-performance 1.14.2
Bundle complete! 2 Gemfile dependencies, 14 gems now installed.
Use `bundle info [gemname]` to see where a bundled gem is installed.

$ bin/rubocop  --only Performance/RegexpMatch
Could not find json-2.6.3 in locally installed gems
Run `bundle install --gemfile /Users/deivid/code/rubygems/rubygems/tool/bundler/lint_gems.rb` to install missing gems.
```

The problem is that our `bin/rubocop` script uses the development
version of Bundler (which has the change causing the problem), but the
advice recommands the default version of Bundler, which does not yet
have the change.

This commit changes the advice to recommend to use the same version of
Bundler that run into the problem in the first place.

So in the above situation you now get:

```
$ bin/rubocop  --only Performance/RegexpMatch
Could not find json-2.6.3 in locally installed gems
Run `/Users/deivid/code/rubygems/rubygems/bundler/exe/bundle install --gemfile /Users/deivid/code/rubygems/rubygems/tool/bundler/lint_gems.rb` to install missing gems.
```

And running that fixes the problem:

```
$ /Users/deivid//rubygems/rubygems/bundler/exe/bundle install --gemfile /Users/deivid/code/rubygems/rubygems/tool/bundler/lint_gems.rb
Fetching gem metadata from https://rubygems.org/.........
Fetching json 2.6.3
Installing json 2.6.3 with native extensions
Bundle complete! 2 Gemfile dependencies, 14 gems now installed.
Use `bundle info [gemname]` to see where a bundled gem is installed.
```

https://github.com/rubygems/rubygems/commit/10a9588c6d
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This problem is quite specific to our dev environment, but I guess the
fix could be handy for other situations.

After merging a change to treat default gems as regular gems, I get this
when trying to run `rubocop` on our repo:

```
$ bin/rubocop  --only Performance/RegexpMatch
Could not find json-2.6.3 in locally installed gems
Run `bundle install --gemfile /Users/deivid/code/rubygems/rubygems/tool/bundler/lint_gems.rb` to install missing gems.
```

However, when running the suggested command, nothing changes and I still
get the same error:

```
$ bundle install --gemfile /Users/deivid/code/rubygems/rubygems/tool/bundler/lint_gems.rb
Using ast 2.4.2
Using bundler 2.4.10
Using json 2.6.3
Using parallel 1.23.0
Using racc 1.7.1
Using parser 3.2.2.3
Using rainbow 3.1.1
Using regexp_parser 2.8.1
Using rexml 3.2.5
Using rubocop-ast 1.29.0
Using ruby-progressbar 1.13.0
Using unicode-display_width 2.4.2
Using rubocop 1.52.1
Using rubocop-performance 1.14.2
Bundle complete! 2 Gemfile dependencies, 14 gems now installed.
Use `bundle info [gemname]` to see where a bundled gem is installed.

$ bin/rubocop  --only Performance/RegexpMatch
Could not find json-2.6.3 in locally installed gems
Run `bundle install --gemfile /Users/deivid/code/rubygems/rubygems/tool/bundler/lint_gems.rb` to install missing gems.
```

The problem is that our `bin/rubocop` script uses the development
version of Bundler (which has the change causing the problem), but the
advice recommands the default version of Bundler, which does not yet
have the change.

This commit changes the advice to recommend to use the same version of
Bundler that run into the problem in the first place.

So in the above situation you now get:

```
$ bin/rubocop  --only Performance/RegexpMatch
Could not find json-2.6.3 in locally installed gems
Run `/Users/deivid/code/rubygems/rubygems/bundler/exe/bundle install --gemfile /Users/deivid/code/rubygems/rubygems/tool/bundler/lint_gems.rb` to install missing gems.
```

And running that fixes the problem:

```
$ /Users/deivid//rubygems/rubygems/bundler/exe/bundle install --gemfile /Users/deivid/code/rubygems/rubygems/tool/bundler/lint_gems.rb
Fetching gem metadata from https://rubygems.org/.........
Fetching json 2.6.3
Installing json 2.6.3 with native extensions
Bundle complete! 2 Gemfile dependencies, 14 gems now installed.
Use `bundle info [gemname]` to see where a bundled gem is installed.
```

https://github.com/rubygems/rubygems/commit/10a9588c6d
</pre>
</div>
</content>
</entry>
<entry>
<title>[rubygems/rubygems] Use match? when regexp match data is unused</title>
<updated>2023-12-13T22:00:26+00:00</updated>
<author>
<name>Samuel Giddins</name>
<email>segiddins@segiddins.me</email>
</author>
<published>2023-12-13T11:46:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=baf2ec2ca8127cd610a3681a1e84ebcb404fe8f2'/>
<id>baf2ec2ca8127cd610a3681a1e84ebcb404fe8f2</id>
<content type='text'>
Improved performance / reduced allocations

https://github.com/rubygems/rubygems/commit/b04726c9a7
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Improved performance / reduced allocations

https://github.com/rubygems/rubygems/commit/b04726c9a7
</pre>
</div>
</content>
</entry>
<entry>
<title>[rubygems/rubygems] Use modern hashes consistently</title>
<updated>2023-12-07T22:29:33+00:00</updated>
<author>
<name>David Rodríguez</name>
<email>deivid.rodriguez@riseup.net</email>
</author>
<published>2023-12-07T21:10:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=2755cb1b2fbc4a5f08ca56345b5945bd452da74e'/>
<id>2755cb1b2fbc4a5f08ca56345b5945bd452da74e</id>
<content type='text'>
https://github.com/rubygems/rubygems/commit/bb66253f2c
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
https://github.com/rubygems/rubygems/commit/bb66253f2c
</pre>
</div>
</content>
</entry>
<entry>
<title>[rubygems/rubygems] major_deprecation accepts :removed_message</title>
<updated>2023-12-01T17:52:37+00:00</updated>
<author>
<name>Eric Mueller</name>
<email>nevinera@gmail.com</email>
</author>
<published>2023-11-30T02:51:55+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=079dfa1812e0f23a74c86e271245504b069b4c17'/>
<id>079dfa1812e0f23a74c86e271245504b069b4c17</id>
<content type='text'>
If supplied, it uses that in place of the message for the case where the
deprecation version is already past.

https://github.com/rubygems/rubygems/commit/1deb73663c
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
If supplied, it uses that in place of the message for the case where the
deprecation version is already past.

https://github.com/rubygems/rubygems/commit/1deb73663c
</pre>
</div>
</content>
</entry>
<entry>
<title>Opaque Etags for compact index requests</title>
<updated>2023-11-27T06:04:40+00:00</updated>
<author>
<name>Josef Šimánek</name>
<email>josef.simanek@gmail.com</email>
</author>
<published>2023-06-27T00:36:59+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=71a8daecd9ad10ba8aa0d66131e326722f1d78ad'/>
<id>71a8daecd9ad10ba8aa0d66131e326722f1d78ad</id>
<content type='text'>
This changes the CompactIndexClient to store etags received from the
compact index in separate files rather than relying on the MD5 checksum
of the file as the etag.

Smoothes the upgrade from md5 etags to opaque by generating them when no
etag file exists. This should reduce the initial impact of changing the
caching behavior by reducing cache misses when the MD5 etag is the same.

Eventually, the MD5 behavior should be retired and the etag should be
considered completely opaque with no assumption that MD5 would match.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This changes the CompactIndexClient to store etags received from the
compact index in separate files rather than relying on the MD5 checksum
of the file as the etag.

Smoothes the upgrade from md5 etags to opaque by generating them when no
etag file exists. This should reduce the initial impact of changing the
caching behavior by reducing cache misses when the MD5 etag is the same.

Eventually, the MD5 behavior should be retired and the etag should be
considered completely opaque with no assumption that MD5 would match.
</pre>
</div>
</content>
</entry>
<entry>
<title>[rubygems/rubygems] Drop support for Ruby 2.6 and Ruby 2.7 in Bundler</title>
<updated>2023-11-13T02:06:10+00:00</updated>
<author>
<name>David Rodríguez</name>
<email>deivid.rodriguez@riseup.net</email>
</author>
<published>2023-10-26T20:12:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=50482cd1e5542f210565440bed7586821f774a29'/>
<id>50482cd1e5542f210565440bed7586821f774a29</id>
<content type='text'>
https://github.com/rubygems/rubygems/commit/93619c97ff
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
https://github.com/rubygems/rubygems/commit/93619c97ff
</pre>
</div>
</content>
</entry>
<entry>
<title>[rubygems/rubygems] Avoid duplicates -rbundler/setup in RUBYOPT with Ruby preview</title>
<updated>2023-10-09T11:54:10+00:00</updated>
<author>
<name>Jacopo</name>
<email>beschi.jacopo@gmail.com</email>
</author>
<published>2023-09-26T08:13:31+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=f44cee90480c103d911836f92a4e0e20c0eca1e5'/>
<id>f44cee90480c103d911836f92a4e0e20c0eca1e5</id>
<content type='text'>
When using a Ruby preview the require path of `bundler/setup` is
similar to `-r/opt/ruby3.3.0-preview2/lib/ruby/3.3.0+0/bundler/setup`.
The special character `+` in the string makes the Regexp fail,
leading to multiple addition of the same require statement each time
`set_rubyopt` is called (e.g. server reloading).
Escaping the characters in the string esure a correct match with all
the different Ruby versions.

https://github.com/rubygems/rubygems/commit/dd43dfa709
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When using a Ruby preview the require path of `bundler/setup` is
similar to `-r/opt/ruby3.3.0-preview2/lib/ruby/3.3.0+0/bundler/setup`.
The special character `+` in the string makes the Regexp fail,
leading to multiple addition of the same require statement each time
`set_rubyopt` is called (e.g. server reloading).
Escaping the characters in the string esure a correct match with all
the different Ruby versions.

https://github.com/rubygems/rubygems/commit/dd43dfa709
</pre>
</div>
</content>
</entry>
<entry>
<title>[rubygems/rubygems] Centralize logic using `Pathname#relative_path_from`</title>
<updated>2023-09-27T05:20:58+00:00</updated>
<author>
<name>Ry Biesemeyer</name>
<email>ry.biesemeyer@elastic.co</email>
</author>
<published>2021-12-02T16:09:36+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=bece8808744ee178a4c55c6954edd30fb93b9ad3'/>
<id>bece8808744ee178a4c55c6954edd30fb93b9ad3</id>
<content type='text'>
To avoid potential crashes when trying to jump from a drive to another
on Windows, and take the change refactor things a bit.

https://github.com/rubygems/rubygems/commit/7c9a9a431a
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
To avoid potential crashes when trying to jump from a drive to another
on Windows, and take the change refactor things a bit.

https://github.com/rubygems/rubygems/commit/7c9a9a431a
</pre>
</div>
</content>
</entry>
</feed>
