Skip to content

Conversation

@johnnyshields
Copy link
Contributor

@johnnyshields johnnyshields commented Jan 2, 2025

This is a follow-up to #8378. Please merge that PR first.

Background

For over 2 years, Rails has included gem "tzinfo-data", platforms: %i[ windows jruby ] in its default Gemfile. The usage of :windows as a platform value is being widely adopted.

The Change

This PR deprecates platform the following platform values :mswin, :mswin64, :mingw, :x64_mingw in favor of :windows.

This PR also fully unifies their "generic platform" behavior to be identical to :windows, as there is no longer any real-world use case where one would want to install a given gem for one flavor of windows but not another. We've already done lots of unification of these platforms already with no user pushback and this PR finishes the job.

This PR also deprecates the associated Gem::Platform constants in favor of WINDOWS; these are unlikely to be used externally.

To further clarify:

  • This PR only affects "generic platform" behavior. Gems which are specific to certain platform architectures such as x64-mingw-ucrt will continue to be specific to only those architectures (i.e. they will not be mistakenly installed on an x64-mswin64 machine, for example.)
  • This PR does not remove any methods or constants, etc. so it should not break anything.

…win64, :mingw, :x64_mingw in favor of using :windows.

This PR also fully unifies their behavior to be identical to :windows, i.e. they no longer are specific to their given architectures as there are basically no gems which are architecture specific. (We've already done lots of unification of these already with no user pushback and this PR finishes the job.)

This PR also deprecates the associated Gem::Platform constants in favor of WINDOWS; these are unlikely to be used externally.
@johnnyshields johnnyshields changed the title Deprecated legacy Windows values (:mingw, etc.) in Bunder DSL platform method Bunder DSL platform method: Deprecate legacy Windows values (:mingw, etc.) in favor of :windows. Jan 2, 2025
[Gem::Platform.new("mswin32"), Gem::Platform.new("windows")],
[Gem::Platform.new("mswin64"), Gem::Platform.new("windows")],
[Gem::Platform.new("mingw32"), Gem::Platform.new("windows")],
[Gem::Platform.new("mingw"), Gem::Platform.new("windows")],
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For the purposes of generics, I've introduced a new virtual OS value "windows" which doesn't actually exist in the wild. Please let me know if I should map all these to "mingw" instead.

@johnnyshields johnnyshields changed the title Bunder DSL platform method: Deprecate legacy Windows values (:mingw, etc.) in favor of :windows. [Specs failing] Bunder DSL platform method: Deprecate legacy Windows values (:mingw, etc.) in favor of :windows. Jan 2, 2025
@johnnyshields johnnyshields changed the title [Specs failing] Bunder DSL platform method: Deprecate legacy Windows values (:mingw, etc.) in favor of :windows. [Tests failing] Bunder DSL platform method: Deprecate legacy Windows values (:mingw, etc.) in favor of :windows. Jan 2, 2025
@johnnyshields
Copy link
Contributor Author

Replaced by #8447

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant