diff --git a/Casks/s/sf.rb b/Casks/s/sf.rb index da5377203b..d6681aff52 100644 --- a/Casks/s/sf.rb +++ b/Casks/s/sf.rb @@ -1,25 +1,22 @@ cask "sf" do arch arm: "arm64", intel: "x64" - version "2.16.10,38f3e4f" - sha256 arm: "f6845bb2d329bdae9ed835f53390b8ad60e335f0cc15cd368cef63803e09b93a", - intel: "18d09197e7cd31519589d7f8117a369b1b0ffb26cc921ce53a9e17ac1165b454" + version "2.16.7" + sha256 :no_check - url "https://developer.salesforce.com/media/salesforce-cli/sf/versions/#{version.csv.first}/#{version.csv.second}/sf-v#{version.csv.first}-#{version.csv.second}-#{arch}.pkg" + url "https://developer.salesforce.com/media/salesforce-cli/sf/channels/stable/sf-#{arch}.pkg" name "Salesforce CLI" desc "Salesforce CLI tools" homepage "https://developer.salesforce.com/tools/salesforcecli" livecheck do - url "https://developer.salesforce.com/media/salesforce-cli/sf/channels/stable/sf-darwin-#{arch}-buildmanifest" - strategy :json do |json| - "#{json["version"]},#{json["sha"]}" - end + url "https://raw.githubusercontent.com/forcedotcom/cli/main/releasenotes/README.md" + regex(/(\d+(?:\.\d+)+)\s+\(.*?\)\s+\[stable\]/i) end depends_on macos: ">= :el_capitan" - pkg "sf-v#{version.csv.first}-#{version.csv.second}-#{arch}.pkg" + pkg "sf-#{arch}.pkg" uninstall pkgutil: "com.salesforce.cli", delete: [