cask "visual-studio-code" do arch arm: "darwin-arm64", intel: "darwin" version "1.84.2" sha256 arm: "3f9ec2a325dd24149bc812488c0bb89496a89b9f4b3ce4ff54a244044d1184e6", intel: "a7be5335aee84643ee4c36e404e87589d8edc8f823d640ae595c3e17cbf0b37f" 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" regex(/"productVersion"\s*:\s*"(\d+(:?\.\d+)+)"/i) end auto_updates true app "Visual Studio Code.app" binary "#{appdir}/Visual Studio Code.app/Contents/Resources/app/bin/code" 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.ShipIt", "~/Library/Caches/com.microsoft.VSCode", "~/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