excalidrawz 1.2.5
[Homebrew/homebrew-cask.git] / Casks / n / noxappplayer.rb
blob1e2ae4dc038f70fd8600eb1012a7ef560eed05a6
1 cask "noxappplayer" do
2   version "3.8.5.7,20211216,23d583db237f4401b01bd0f549acfda1"
3   sha256 "733ec0b6b53114f60f178195fcd91fe24e3ea2304ab4e16d62f0c0d3f28029c7"
5   url "https://res06.bignox.com/full/#{version.csv.second}/#{version.csv.third}.dmg?filename=NoxInstaller_#{version.csv.first}_en.dmg"
6   name "NoxAppPlayer"
7   desc "Android emulator to play mobile games"
8   homepage "https://www.bignox.com/"
10   livecheck do
11     url "https://www.bignox.com/en/download/fullPackage/mac_fullzip"
12     regex(%r{/(\d+)/([^/]+)\.dmg\?filename=NoxInstaller_(\d+(?:\.\d+)*)_en\.dmg}i)
13     strategy :header_match do |headers, regex|
14       match = headers["location"]&.match(regex)
15       next if match.blank?
17       "#{match[3]},#{match[1]},#{match[2]}"
18     end
19   end
21   container nested: "NoxAppPlayerInstaller.app/Contents/MacOS/NoxAppPlayer.zip"
23   app "NoxAppPlayer.app"
25   zap trash: [
26     "~/Library/Application Support/NoxAppPlayer",
27     "~/Library/Saved Application State/com.nox.NoxAppPlayer.savedState",
28   ]
30   caveats do
31     requires_rosetta
32   end
33 end