52 lines
1.9 KiB
Ruby
52 lines
1.9 KiB
Ruby
cask "microsoft-edge@beta" do
|
|
linkid = on_arch_conditional arm: "2099618", intel: "2069439"
|
|
|
|
on_arm do
|
|
version "126.0.2592.56,24b2e12e-fdc4-4f52-ad88-8029b0a8cc8d"
|
|
sha256 "6b44945abdb8855da547c115d0e74712231521a851a49a1f7437bbedaa5c3975"
|
|
end
|
|
on_intel do
|
|
version "126.0.2592.56,cc46dc16-0a5b-4c7c-9630-2ea9dda76640"
|
|
sha256 "eca3b73c6818b743e8d8bd3671ec1e9fb2768818e40f3b490b79b5875cf34c7f"
|
|
end
|
|
|
|
url "https://msedge.sf.dl.delivery.mp.microsoft.com/filestreamingservice/files/#{version.csv.second}/MicrosoftEdgeBeta-#{version.csv.first}.pkg"
|
|
name "Microsoft Edge Beta"
|
|
desc "Multi-platform web browser"
|
|
homepage "https://www.microsoft.com/en-us/edge/download/insider?form="
|
|
|
|
livecheck do
|
|
url "https://go.microsoft.com/fwlink/?linkid=#{linkid}"
|
|
regex(%r{/([^/]+)/MicrosoftEdgeBeta[._-]v?(\d+(?:\.\d+)+)\.pkg}i)
|
|
strategy :header_match do |headers, regex|
|
|
headers["location"].scan(regex).map { |match| "#{match[1]},#{match[0]}" }
|
|
end
|
|
end
|
|
|
|
auto_updates true
|
|
|
|
pkg "MicrosoftEdgeBeta-#{version.csv.first}.pkg",
|
|
choices: [
|
|
{
|
|
"choiceIdentifier" => "com.microsoft.package.Microsoft_AutoUpdate.app", # Office16_all_autoupdate.pkg
|
|
"choiceAttribute" => "selected",
|
|
"attributeSetting" => 0,
|
|
},
|
|
]
|
|
|
|
uninstall launchctl: [
|
|
"com.microsoft.EdgeUpdater.update-internal.109.0.1518.89.system",
|
|
"com.microsoft.EdgeUpdater.update.system",
|
|
"com.microsoft.EdgeUpdater.wake.109.0.1518.89.system",
|
|
"com.microsoft.EdgeUpdater.wake.system",
|
|
],
|
|
pkgutil: "com.microsoft.edgemac.Beta"
|
|
|
|
zap trash: [
|
|
"~/Library/Application Support/Microsoft Edge Beta",
|
|
"~/Library/Caches/Microsoft Edge Beta",
|
|
"~/Library/Preferences/com.microsoft.edgemac.Beta.plist",
|
|
"~/Library/Saved Application State/com.microsoft.edgemac.Beta.savedState",
|
|
]
|
|
end
|