From 4e896ad75b9968e612881a97c4faf324dd02248f Mon Sep 17 00:00:00 2001 From: Klaus Hipp Date: Fri, 5 Jul 2024 09:04:00 +0200 Subject: [PATCH] gitfox: update livecheck --- Casks/g/gitfox.rb | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/Casks/g/gitfox.rb b/Casks/g/gitfox.rb index 0e38b4bbb80c..a0e81cdf62a3 100644 --- a/Casks/g/gitfox.rb +++ b/Casks/g/gitfox.rb @@ -9,12 +9,18 @@ homepage "https://www.gitfox.app/" livecheck do - url "https://storage.googleapis.com/gitfox/Gitfox.latest.stable.zip" - strategy :extract_plist + url "https://api.gitfox.app/v1/versions" + strategy :json do |json| + json.dig("response", "builds")&.map do |item| + next if !item["short_version_string"] || !item["build"] + + "#{item["short_version_string"]},#{item["build"]}" + end + end end auto_updates true - depends_on macos: ">= :monterey" + depends_on macos: ">= :ventura" app "Gitfox.app" binary "#{appdir}/Gitfox.app/Contents/SharedSupport/bin/gitfox-cli", target: "gitfox"