Skip to content

Commit

Permalink
retroshare: update version, livecheck, add Rosetta
Browse files Browse the repository at this point in the history
Signed-off-by: Justin Krehel <[email protected]>
  • Loading branch information
krehel committed Sep 7, 2024
1 parent 6221870 commit 0135435
Showing 1 changed file with 23 additions and 4 deletions.
27 changes: 23 additions & 4 deletions Casks/r/retroshare.rb
Original file line number Diff line number Diff line change
@@ -1,17 +1,36 @@
cask "retroshare" do
version "0.6.6"
sha256 "9a52ae0da3235faba1cb3f4e2b59916d1d0883378ab538c443122f96b935335d"
version "0.6.7.2,0.6.7a,0c03e93a4-01-03-2024,10.15.7,5.15.11"
sha256 "6757a0bffba36fd85515117edba7e821bb3105500f8a282be942abeee3373230"

url "https://github.com/RetroShare/RetroShare/releases/download/v#{version}/RetroShare-#{version}-MacOS-10.14-Qt-5.14.1.dmg",
url "https://github.com/RetroShare/RetroShare/releases/download/v#{version.csv.first}/RetroShare-#{version.csv.second}-#{version.csv.third}-MacOS-#{version.csv.fourth}-Qt-#{version.csv.fifth}.dmg",
verified: "github.com/RetroShare/RetroShare/"
name "RetroShare"
desc "Friend-2-Friend and secure decentralised communication platform"
homepage "https://retroshare.cc/"

livecheck do
url :url
strategy :github_latest
regex(/Retroshare[._-](\d+(?:\.\d+)+[a-z]?)+[._-]([\h-]+)+[._-]MacOS[._-](\d+(?:\.\d+)+)[._-]Qt[._-](\d+(?:\.\d+)+)\.dmg$/i)

Check failure on line 13 in Casks/r/retroshare.rb

View workflow job for this annotation

GitHub Actions / syntax (macos-14)

Layout/LineLength: Line is too long. [128/118]
strategy :github_releases do |json, regex|
json.map do |release|
next if release["draft"] || release["prerelease"]

tag_version = release["tag_name"][/^v?(\d+(?:\.\d+)+)$/i, 1]
next if tag_version.blank?

release["assets"]&.map do |asset|
match = asset["name"]&.match(regex)
next if match.blank?

"#{tag_version},#{match[1]},#{match[2]},#{match[3]},#{match[4]}"
end
end.flatten
end
end

app "retroshare.app"

caveats do
requires_rosetta
end
end

0 comments on commit 0135435

Please sign in to comment.