Skip to content

Commit fef0051

Browse files
deivid-rodriguezhsbt
authored andcommitted
[rubygems/rubygems] Remove auto_clean_without_path setting
There already different ways of toggling off this behavior, like setting `bundle config clean false`, or configuring Bundler to install to system gems with `bundle config path.system true`. ruby/rubygems@6daa09f60a
1 parent 4d7e622 commit fef0051

37 files changed

+37
-44
lines changed

lib/bundler/cli/common.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ def self.patch_level_options(options)
130130
def self.clean_after_install?
131131
clean = Bundler.settings[:clean]
132132
return clean unless clean.nil?
133-
clean ||= Bundler.feature_flag.auto_clean_without_path? && Bundler.settings[:path].nil?
133+
clean ||= Bundler.feature_flag.bundler_4_mode? && Bundler.settings[:path].nil?
134134
clean &&= !Bundler.use_system_gems?
135135
clean
136136
end

lib/bundler/feature_flag.rb

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,6 @@ def self.settings_method(name, key, &default)
2828
(1..10).each {|v| define_method("bundler_#{v}_mode?") { @major_version >= v } }
2929

3030
settings_flag(:allow_offline_install) { bundler_4_mode? }
31-
settings_flag(:auto_clean_without_path) { bundler_4_mode? }
3231
settings_flag(:cache_all) { bundler_4_mode? }
3332
settings_flag(:default_install_uses_path) { bundler_4_mode? }
3433
settings_flag(:forget_cli_options) { bundler_4_mode? }

lib/bundler/man/bundle-add.1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
.\" generated with Ronn-NG/v0.10.1
22
.\" http://github.com/apjanke/ronn-ng/tree/0.10.1
3-
.TH "BUNDLE\-ADD" "1" "June 2025" ""
3+
.TH "BUNDLE\-ADD" "1" "July 2025" ""
44
.SH "NAME"
55
\fBbundle\-add\fR \- Add gem to the Gemfile and run bundle install
66
.SH "SYNOPSIS"

lib/bundler/man/bundle-binstubs.1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
.\" generated with Ronn-NG/v0.10.1
22
.\" http://github.com/apjanke/ronn-ng/tree/0.10.1
3-
.TH "BUNDLE\-BINSTUBS" "1" "June 2025" ""
3+
.TH "BUNDLE\-BINSTUBS" "1" "July 2025" ""
44
.SH "NAME"
55
\fBbundle\-binstubs\fR \- Install the binstubs of the listed gems
66
.SH "SYNOPSIS"

lib/bundler/man/bundle-cache.1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
.\" generated with Ronn-NG/v0.10.1
22
.\" http://github.com/apjanke/ronn-ng/tree/0.10.1
3-
.TH "BUNDLE\-CACHE" "1" "June 2025" ""
3+
.TH "BUNDLE\-CACHE" "1" "July 2025" ""
44
.SH "NAME"
55
\fBbundle\-cache\fR \- Package your needed \fB\.gem\fR files into your application
66
.SH "SYNOPSIS"

lib/bundler/man/bundle-check.1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
.\" generated with Ronn-NG/v0.10.1
22
.\" http://github.com/apjanke/ronn-ng/tree/0.10.1
3-
.TH "BUNDLE\-CHECK" "1" "June 2025" ""
3+
.TH "BUNDLE\-CHECK" "1" "July 2025" ""
44
.SH "NAME"
55
\fBbundle\-check\fR \- Verifies if dependencies are satisfied by installed gems
66
.SH "SYNOPSIS"

lib/bundler/man/bundle-clean.1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
.\" generated with Ronn-NG/v0.10.1
22
.\" http://github.com/apjanke/ronn-ng/tree/0.10.1
3-
.TH "BUNDLE\-CLEAN" "1" "June 2025" ""
3+
.TH "BUNDLE\-CLEAN" "1" "July 2025" ""
44
.SH "NAME"
55
\fBbundle\-clean\fR \- Cleans up unused gems in your bundler directory
66
.SH "SYNOPSIS"

lib/bundler/man/bundle-config.1

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
.\" generated with Ronn-NG/v0.10.1
22
.\" http://github.com/apjanke/ronn-ng/tree/0.10.1
3-
.TH "BUNDLE\-CONFIG" "1" "June 2025" ""
3+
.TH "BUNDLE\-CONFIG" "1" "July 2025" ""
44
.SH "NAME"
55
\fBbundle\-config\fR \- Set bundler configuration options
66
.SH "SYNOPSIS"
@@ -56,9 +56,6 @@ The following is a list of all configuration keys and their purpose\. You can le
5656
\fBallow_offline_install\fR (\fBBUNDLE_ALLOW_OFFLINE_INSTALL\fR)
5757
Allow Bundler to use cached data when installing without network access\.
5858
.TP
59-
\fBauto_clean_without_path\fR (\fBBUNDLE_AUTO_CLEAN_WITHOUT_PATH\fR)
60-
Automatically run \fBbundle clean\fR after installing when an explicit \fBpath\fR has not been set and Bundler is not installing into the system gems\.
61-
.TP
6259
\fBauto_install\fR (\fBBUNDLE_AUTO_INSTALL\fR)
6360
Automatically run \fBbundle install\fR when gems are missing\.
6461
.TP
@@ -75,7 +72,7 @@ Cache gems for all platforms\.
7572
The directory that bundler will place cached gems in when running \fBbundle package\fR, and that bundler will look in when installing gems\. Defaults to \fBvendor/cache\fR\.
7673
.TP
7774
\fBclean\fR (\fBBUNDLE_CLEAN\fR)
78-
Whether Bundler should run \fBbundle clean\fR automatically after \fBbundle install\fR\.
75+
Whether Bundler should run \fBbundle clean\fR automatically after \fBbundle install\fR\. Defaults to \fBtrue\fR in Bundler 4, as long as \fBpath\fR is not explicitly configured\.
7976
.TP
8077
\fBconsole\fR (\fBBUNDLE_CONSOLE\fR)
8178
The console that \fBbundle console\fR starts\. Defaults to \fBirb\fR\.

lib/bundler/man/bundle-config.1.ronn

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -79,9 +79,6 @@ learn more about their operation in [bundle install(1)](bundle-install.1.html).
7979

8080
* `allow_offline_install` (`BUNDLE_ALLOW_OFFLINE_INSTALL`):
8181
Allow Bundler to use cached data when installing without network access.
82-
* `auto_clean_without_path` (`BUNDLE_AUTO_CLEAN_WITHOUT_PATH`):
83-
Automatically run `bundle clean` after installing when an explicit `path`
84-
has not been set and Bundler is not installing into the system gems.
8582
* `auto_install` (`BUNDLE_AUTO_INSTALL`):
8683
Automatically run `bundle install` when gems are missing.
8784
* `bin` (`BUNDLE_BIN`):
@@ -98,7 +95,8 @@ learn more about their operation in [bundle install(1)](bundle-install.1.html).
9895
Defaults to `vendor/cache`.
9996
* `clean` (`BUNDLE_CLEAN`):
10097
Whether Bundler should run `bundle clean` automatically after
101-
`bundle install`.
98+
`bundle install`. Defaults to `true` in Bundler 4, as long as `path` is not
99+
explicitly configured.
102100
* `console` (`BUNDLE_CONSOLE`):
103101
The console that `bundle console` starts. Defaults to `irb`.
104102
* `default_install_uses_path` (`BUNDLE_DEFAULT_INSTALL_USES_PATH`):

lib/bundler/man/bundle-console.1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
.\" generated with Ronn-NG/v0.10.1
22
.\" http://github.com/apjanke/ronn-ng/tree/0.10.1
3-
.TH "BUNDLE\-CONSOLE" "1" "June 2025" ""
3+
.TH "BUNDLE\-CONSOLE" "1" "July 2025" ""
44
.SH "NAME"
55
\fBbundle\-console\fR \- Open an IRB session with the bundle pre\-loaded
66
.SH "SYNOPSIS"

0 commit comments

Comments
 (0)