excalidrawz 1.2.5
[Homebrew/homebrew-cask.git] / Casks / s / sys-pc-tool.rb
blob5523ed9d89210ffc39fa84535efa2620b5d036ef
1 cask "sys-pc-tool" do
2   version "6.33"
3   sha256 "509e6b833c7fc907c3c0989704b941acba6f9d13abe5f0c20834ee4d77eb0c4f"
5   url "https://www.syride.com/downloads/SYS_PC_Tool_setup_mac-#{version}.pkg"
6   name "SYS PC Tool"
7   desc "Software for Syride instruments"
8   homepage "https://www.syride.com/"
10   livecheck do
11     url "http://www.syride.com/downloads/SYS_PC_Tool/webconfig-para4.xml"
12     regex(/SYS[._-]PC[._-]Tool[._-]setup[._-]mac[._-]v?(\d+(?:[.-]\d+)+)\.pkg/i)
13     strategy :xml do |xml, regex|
14       url = xml.elements["//sysui_config[@machine='mac']/file"]&.text&.strip
15       match = url.match(regex) if url
17       match[1]
18     end
19   end
21   auto_updates true
22   depends_on macos: ">= :sierra"
24   pkg "SYS_PC_TOOL_setup_mac-#{version}.pkg"
26   uninstall pkgutil: "com.syride.syspctool",
27             delete:  "/Applications/SYS-PC-Tool.app"
29   zap trash: [
30     "~/.syride",
31     "~/Library/Saved Application State/Syride.SYS-PC-Tool.savedState",
32     "~/syride",
33   ]
34 end