Skip to content

Commit 478c3ff

Browse files
hsbtclaude
andcommitted
Recognize cooldown as an integer Bundler setting
Adds `cooldown` to NUMBER_KEYS so that `BUNDLE_COOLDOWN` and `bundle config set cooldown` are parsed as integer days. Reading the value is enough for now; later commits plumb it into the resolver and the Gemfile DSL. #9113 Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
1 parent cd61070 commit 478c3ff

2 files changed

Lines changed: 6 additions & 0 deletions

File tree

bundler/lib/bundler/settings.rb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ class Settings
4444
].freeze
4545

4646
NUMBER_KEYS = %w[
47+
cooldown
4748
jobs
4849
redirect
4950
retry

spec/bundler/settings_spec.rb

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -119,6 +119,11 @@
119119
settings.set_local :ssl_verify_mode, "1"
120120
expect(settings[:ssl_verify_mode]).to be 1
121121
end
122+
123+
it "coerces cooldown to integer" do
124+
settings.set_local :cooldown, "7"
125+
expect(settings[:cooldown]).to be 7
126+
end
122127
end
123128

124129
context "when it's not possible to create the settings directory" do

0 commit comments

Comments
 (0)