mirror of
https://github.com/wavetermdev/homebrew-cask.git
synced 2026-08-05 13:43:24 -07:00
32 lines
887 B
Ruby
32 lines
887 B
Ruby
cask "gnucash" do
|
|
version "5.4-2"
|
|
sha256 "ffe311fd2077cf1df15c253a5e062dc3801fa9db06829d3d12184184727e89c8"
|
|
|
|
url "https://github.com/Gnucash/gnucash/releases/download/#{version.hyphens_to_dots.major_minor}/Gnucash-Intel-#{version}.dmg",
|
|
verified: "github.com/Gnucash/gnucash/"
|
|
name "GnuCash"
|
|
desc "Double-entry accounting program"
|
|
homepage "https://www.gnucash.org/"
|
|
|
|
livecheck do
|
|
url :url
|
|
regex(/^Gnucash-Intel[._-]v?(\d+(?:[.-]\d+)+)\.dmg$/i)
|
|
strategy :github_latest do |json, regex|
|
|
json["assets"]&.map do |asset|
|
|
match = asset["name"]&.match(regex)
|
|
next if match.blank?
|
|
|
|
match[1]
|
|
end
|
|
end
|
|
end
|
|
|
|
app "Gnucash.app"
|
|
|
|
zap trash: [
|
|
"~/Library/Application Support/Gnucash",
|
|
"~/Library/Preferences/org.gnucash.Gnucash.plist",
|
|
"~/Library/Saved Application State/org.gnucash.Gnucash.savedState",
|
|
]
|
|
end
|