mirror of
https://github.com/Homebrew/brew.git
synced 2025-07-14 16:09:03 +08:00

This updates logic to add a `#scheme_and_version` method to be used with `.sort_by` and `.max_by`. Using `Keg#version` by itself can be inaccurate when different version schemes are present. This also updates the behavior of `Formula#eligible_kegs_for_cleanup` to match the previous behavior. We were dropping the wrong keg based on the sort being reversed in a previous PR.