Skip to content

Commit

Permalink
Merge pull request #199523 from Homebrew/update-bluewallet
Browse files Browse the repository at this point in the history
bluewallet: add livecheck
  • Loading branch information
daeho-ro authored Jan 25, 2025
2 parents 23125b6 + d1bbca0 commit f094831
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions Casks/b/bluewallet.rb
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,25 @@
desc "Bitcoin wallet and Lightning wallet"
homepage "https://bluewallet.io/"

# 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
regex(/^BlueWallet[._-]v?(\d+(?:\.\d+)+)\.dmg$/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

depends_on macos: ">= :big_sur"

app "BlueWallet.app"
Expand Down

0 comments on commit f094831

Please sign in to comment.