You've already forked homebrew-cask
mirror of
https://github.com/wavetermdev/homebrew-cask.git
synced 2026-04-22 15:25:17 -07:00
42 lines
1.4 KiB
Ruby
42 lines
1.4 KiB
Ruby
cask "visual-studio-code" do
|
|
arch arm: "darwin-arm64", intel: "darwin"
|
|
|
|
version "1.87.1"
|
|
sha256 arm: "920fe482947ddf848fc3c216c2b45114d873ce5231d24da00f180b913ea912f2",
|
|
intel: "28e3432a7d78f43c547a40ffe4cfe598604381f50bc423b8eb7a14f66381ce06"
|
|
|
|
url "https://update.code.visualstudio.com/#{version}/#{arch}/stable"
|
|
name "Microsoft Visual Studio Code"
|
|
name "VS Code"
|
|
desc "Open-source code editor"
|
|
homepage "https://code.visualstudio.com/"
|
|
|
|
livecheck do
|
|
url "https://update.code.visualstudio.com/api/update/#{arch}/stable/latest"
|
|
strategy :json do |json|
|
|
json["productVersion"]
|
|
end
|
|
end
|
|
|
|
auto_updates true
|
|
depends_on macos: ">= :catalina"
|
|
|
|
app "Visual Studio Code.app"
|
|
binary "#{appdir}/Visual Studio Code.app/Contents/Resources/app/bin/code"
|
|
|
|
uninstall launchctl: "com.microsoft.VSCode.ShipIt",
|
|
quit: "com.microsoft.VSCode"
|
|
|
|
zap trash: [
|
|
"~/.vscode",
|
|
"~/Library/Application Support/Code",
|
|
"~/Library/Application Support/com.apple.sharedfilelist/com.apple.LSSharedFileList.ApplicationRecentDocuments/com.microsoft.vscode.sfl*",
|
|
"~/Library/Caches/com.microsoft.VSCode",
|
|
"~/Library/Caches/com.microsoft.VSCode.ShipIt",
|
|
"~/Library/Preferences/ByHost/com.microsoft.VSCode.ShipIt.*.plist",
|
|
"~/Library/Preferences/com.microsoft.VSCode.helper.plist",
|
|
"~/Library/Preferences/com.microsoft.VSCode.plist",
|
|
"~/Library/Saved Application State/com.microsoft.VSCode.savedState",
|
|
]
|
|
end
|