Skip to content

Commit

Permalink
Merge pull request #196695 from Homebrew/update-tunnelblick
Browse files Browse the repository at this point in the history
tunnelblick: update livecheck
  • Loading branch information
bevanjkay authored Dec 29, 2024
2 parents 0bba42e + fcaad86 commit 696b306
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions Casks/t/tunnelblick.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,16 @@
version "4.0.1,5971"
sha256 "403b0e9bb110dd9ce3251d8921cb81751e195623e6b579847b1db6fbb2e44031"

url "https://github.com/Tunnelblick/Tunnelblick/releases/download/v#{version.csv.first}/Tunnelblick_#{version.csv.first}_build_#{version.csv.second}.dmg",
verified: "github.com/Tunnelblick/Tunnelblick/"
url "https://tunnelblick.net/iprelease/Tunnelblick_#{version.csv.first}_build_#{version.csv.second}.dmg"
name "Tunnelblick"
desc "Free and open-source OpenVPN client"
homepage "https://www.tunnelblick.net/"

livecheck do
url :url
regex(/Tunnelblick\s+v?(\d+(?:\.\d+)+[a-z]?)\s+\(build\s+(\d+(?:\.\d+)*)\)/i)
strategy :github_latest do |json, regex|
match = json["name"]&.match(regex)
url "https://tunnelblick.net/appcast-s.rss"
regex(/^v?(\d+(?:\.\d+)+[a-z]?)\s+\(build\s+(\d+(?:\.\d+)*)\)$/i)
strategy :sparkle do |item, regex|
match = item.short_version&.match(regex)
next if match.blank?

"#{match[1]},#{match[2]}"
Expand Down

0 comments on commit 696b306

Please sign in to comment.