forked from Homebrew/homebrew-cask
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
2fc0666
commit 18f2ba3
Showing
2 changed files
with
56 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
cask "tunnelblick@beta" do | ||
version "5.0.1beta01,6020" | ||
sha256 "2c195ec32862c4845c53b03c506ee84464f482e6f39c4619aa94377b6165554e" | ||
|
||
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/" | ||
name "Tunnelblick" | ||
desc "Free and open source graphic user interface for OpenVPN" | ||
homepage "https://www.tunnelblick.net/" | ||
|
||
livecheck do | ||
url :url | ||
regex(/^Tunnelblick[._-]v?(\d+(?:\.\d+)+[._-]?beta\d+[a-z]?)[._-]build[._-](\d+)\.(?:dmg|pkg)$/i) | ||
strategy :github_releases do |json, regex| | ||
json.map do |release| | ||
next if release["draft"] | ||
|
||
release["assets"]&.map do |asset| | ||
match = asset["name"]&.match(regex) | ||
next if match.blank? | ||
|
||
"#{match[1]},#{match[2]}" | ||
end | ||
end.flatten | ||
end | ||
end | ||
|
||
auto_updates true | ||
depends_on macos: ">= :high_sierra" | ||
|
||
app "Tunnelblick.app" | ||
|
||
uninstall_preflight do | ||
set_ownership "#{appdir}/Tunnelblick.app" | ||
end | ||
|
||
uninstall launchctl: [ | ||
"net.tunnelblick.tunnelblick.LaunchAtLogin", | ||
"net.tunnelblick.tunnelblick.tunnelblickd", | ||
], | ||
quit: "net.tunnelblick.tunnelblick" | ||
|
||
zap trash: [ | ||
"/Library/Application Support/Tunnelblick", | ||
"~/Library/Application Support/Tunnelblick", | ||
"~/Library/Caches/com.apple.helpd/SDMHelpData/Other/English/HelpSDMIndexFile/net.tunnelblick.tunnelblick.help*", | ||
"~/Library/Caches/net.tunnelblick.tunnelblick", | ||
"~/Library/Preferences/net.tunnelblick.tunnelblick.plist", | ||
] | ||
|
||
caveats <<~EOS | ||
For security reasons, #{token} must be installed to /Applications, | ||
and will request to be moved at launch. | ||
EOS | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters