/
automattic-texts.rb
39 lines (32 loc) 路 1.07 KB
/
automattic-texts.rb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
cask "automattic-texts" do
arch arm: "arm64", intel: "x64"
on_arm do
version "0.83.8,3356c9f1f2"
sha256 "974f9e0e6f37643f5cec65ead5c2fd8b690e1fa4898385d2bf2d1d419748643c"
end
on_intel do
version "0.83.8,f26091ab9e"
sha256 "2a6748a29f31b143d2e79688d79ccec0b07f52bb180a479a2b28dc62e90e75e4"
end
url "https://texts-binaries.texts.com/builds/Texts-macOS-#{arch}-v#{version.csv.first}-#{version.csv.second}.zip"
name "Texts.com"
desc "DM Manager"
homepage "https://texts.com/"
livecheck do
url "https://texts.com/api/install/macos/#{arch}/latest.zip"
regex(/Texts[._-]macOS[._-]#{arch}[._-]v?(\d+(?:\.\d+)+)[._-](\h+)\.zip/i)
strategy :header_match do |headers, regex|
match = headers["location"].match(regex)
next if match.blank?
"#{match[1]},#{match[2]}"
end
end
depends_on macos: ">= :catalina"
app "Texts.app"
zap trash: [
"~/Library/Application Support/Texts",
"~/Library/Caches/io.texts.Texts",
"~/Library/HTTPStorages/io.texts.Texts",
"~/Library/Preferences/com.texts.Texts.plist",
]
end