info: show latest version

This commit is contained in:
Rylan Polster 2021-07-14 00:26:09 -04:00
parent cc03c2c15c
commit 91fffeeff6
No known key found for this signature in database
GPG Key ID: 46A744940CFF4D64

View File

@ -244,7 +244,13 @@ module Homebrew
specs = [] specs = []
if (stable = f.stable) if (stable = f.stable)
s = "stable #{stable.version}" latest_version = if ENV["HOMEBREW_JSON_CORE"].present?
BottleAPI.latest_pkg_version(f.name).version || stable.version
else
stable.version
end
s = "stable #{latest_version}"
s += " (bottled)" if stable.bottled? && f.pour_bottle? s += " (bottled)" if stable.bottled? && f.pour_bottle?
specs << s specs << s
end end