appium-inspector: update livecheck

This commit is contained in:
Patrick Linnane
2023-10-18 12:07:23 -07:00
parent 4fc43347d5
commit f2973692d2
+15 -1
View File
@@ -7,9 +7,23 @@ cask "appium-inspector" do
desc "GUI inspector for mobile apps"
homepage "https://github.com/appium/appium-inspector/"
# Not every GitHub release provides a file for macOS, so we check multiple
# recent releases instead of only the "latest" release.
livecheck do
url :url
strategy :github_latest
regex(/^Appium.*?mac[._-]v?(\d+(?:\.\d+)+)\.(?:dmg|pkg|zip)$/i)
strategy :github_releases do |json, regex|
json.map do |release|
next if release["draft"] || release["prerelease"]
release["assets"]&.map do |asset|
match = asset["name"]&.match(regex)
next if match.blank?
match[1]
end
end.flatten
end
end
app "Appium Inspector.app"