diff --git a/Casks/c/command-x.rb b/Casks/c/command-x.rb index 2ef02f9f7b..42a117bb1f 100644 --- a/Casks/c/command-x.rb +++ b/Casks/c/command-x.rb @@ -1,18 +1,18 @@ cask "command-x" do - version "1.0.6,1684086547" + version "1.0.6-1684086547-1701611235,yubkc4dmr2xy89ja4r4hr,xa0zqmllf0uwrm55latddna99" sha256 "48601491924bf431c6cf9a9bb5e619e5e60b6212521b9385e55fdb1db729217c" - url "https://dsc.cloud/sindresorhus/Command-X-#{version.csv.first}-#{version.csv.second}.zip", - verified: "dsc.cloud/sindresorhus/" + url "https://www.dropbox.com/scl/fi/#{version.csv.second}/Command-X-#{version.major_minor_patch}.zip?rlkey=#{version.csv.third}&raw=1", + verified: "dropbox.com/scl/fi/" name "Command X" desc "Cut and paste files in Finder" homepage "https://sindresorhus.com/command-x" livecheck do url :homepage - regex(/href.*?Command[._-]X[._-](\d+(?:\.\d+)+)-(\w+)\.zip"/i) + regex(%r{href.*?/scl/fi/(\w+)/Command-X-([\d.-]+)\.zip\?rlkey=(\w+)}i) strategy :page_match do |page, regex| - page.scan(regex).map { |match| "#{match[0]},#{match[1]}" } + page.scan(regex).map { |match| "#{match[1]},#{match[0]},#{match[2]}" } end end @@ -24,4 +24,9 @@ cask "command-x" do "~/Library/Application Scripts/com.sindresorhus.Command-X", "~/Library/Containers/com.sindresorhus.Command-X", ] + + caveats <<~EOS + This variant of #{token} is only updated annually or when security vulnerabilities are discovered. + For a more frequently updated versio, install via the Mac App Store. + EOS end