cask: remove os_versions
This was originally used by the API but was replaced months ago by SimulateSystem. Essentially, it's only current use was in the #to_h method but is not used internally at all when creating cask instances from the API JSON.
This commit is contained in:
parent
ac0663ae5d
commit
1322b9cb79
@ -114,24 +114,6 @@ module Cask
|
||||
.reverse
|
||||
end
|
||||
|
||||
def os_versions
|
||||
# TODO: use #to_hash_with_variations instead once all casks use on_system blocks
|
||||
@os_versions ||= begin
|
||||
version_os_hash = {}
|
||||
actual_version = MacOS.full_version.to_s
|
||||
|
||||
MacOSVersions::SYMBOLS.each do |os_name, os_version|
|
||||
MacOS.full_version = os_version
|
||||
cask = CaskLoader.load(full_name)
|
||||
version_os_hash[os_name] = cask.version if cask.version != version
|
||||
end
|
||||
|
||||
version_os_hash
|
||||
ensure
|
||||
MacOS.full_version = actual_version if actual_version
|
||||
end
|
||||
end
|
||||
|
||||
def full_name
|
||||
return token if tap.nil?
|
||||
return token if tap.user == "Homebrew"
|
||||
@ -307,7 +289,6 @@ module Cask
|
||||
"url_specs" => url_specs,
|
||||
"appcast" => appcast,
|
||||
"version" => version,
|
||||
"versions" => os_versions,
|
||||
"installed" => versions.last,
|
||||
"outdated" => outdated?,
|
||||
"sha256" => sha256,
|
||||
|
@ -10,8 +10,6 @@
|
||||
"url": "https://www.example.com/cask/caffeine.zip",
|
||||
"appcast": null,
|
||||
"version": "1.2.3",
|
||||
"versions": {
|
||||
},
|
||||
"installed": null,
|
||||
"outdated": false,
|
||||
"sha256": "67cdb8a02803ef37fdbf7e0be205863172e41a561ca446cd84f0d7ab35a99d94",
|
||||
|
@ -16,8 +16,6 @@
|
||||
},
|
||||
"appcast": null,
|
||||
"version": "1.2.3",
|
||||
"versions": {
|
||||
},
|
||||
"installed": null,
|
||||
"outdated": false,
|
||||
"sha256": "c64c05bdc0be845505d6e55e69e696a7f50d40846e76155f0c85d5ff5e7bbb84",
|
||||
|
Loading…
x
Reference in New Issue
Block a user