Skip to content

Commit 3d60d3b

Browse files
authored
Merge pull request rails#53363 from kamipo/get_rid_of_bundler_windows_platforms
Get rid of `bundler_windows_platforms`
2 parents 3deec36 + 1f938f4 commit 3d60d3b

File tree

4 files changed

+3
-8
lines changed

4 files changed

+3
-8
lines changed

railties/lib/rails/generators/app_base.rb

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -659,10 +659,6 @@ def bundle_install?
659659
!(options[:skip_bundle] || options[:pretend])
660660
end
661661

662-
def bundler_windows_platforms
663-
Gem.rubygems_version >= Gem::Version.new("3.3.22") ? "windows" : "mswin mswin64 mingw x64_mingw"
664-
end
665-
666662
def depends_on_system_test?
667663
!(options[:skip_system_test] || options[:skip_test] || options[:api])
668664
end

railties/lib/rails/generators/rails/app/templates/Gemfile.tt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ source "https://rubygems.org"
1010
<% end -%>
1111

1212
# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
13-
gem "tzinfo-data", platforms: %i[ <%= bundler_windows_platforms %> jruby ]
13+
gem "tzinfo-data", platforms: %i[ windows jruby ]
1414
<% unless options.skip_solid? -%>
1515

1616
<% if options.skip_action_cable? -%>
@@ -53,7 +53,7 @@ gem "thruster", require: false
5353

5454
group :development, :test do
5555
# See https://guides.rubyonrails.org/debugging_rails_applications.html#debugging-with-the-debug-gem
56-
gem "debug", platforms: %i[ mri <%= bundler_windows_platforms %> ], require: "debug/prelude"
56+
gem "debug", platforms: %i[ mri windows ], require: "debug/prelude"
5757
<%- unless options.skip_brakeman? -%>
5858

5959
# Static analysis for security vulnerabilities [https://brakemanscanner.org/]

railties/lib/rails/generators/rails/plugin/templates/Gemfile.tt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,5 +19,5 @@ gem "rubocop-rails-omakase", require: false
1919
<% end -%>
2020
<% if RUBY_PLATFORM.match?(/mingw|mswin|java/) -%>
2121

22-
gem "tzinfo-data", platforms: %i[ <%= bundler_windows_platforms %> jruby ]
22+
gem "tzinfo-data", platforms: %i[ windows jruby ]
2323
<% end -%>

railties/test/generators/generators_test_helper.rb

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,6 @@ def gemfile_locals
156156
depend_on_bootsnap: false,
157157
depends_on_system_test: false,
158158
options: ActiveSupport::OrderedOptions.new,
159-
bundler_windows_platforms: "windows",
160159
}
161160
end
162161
end

0 commit comments

Comments
 (0)