From b4c8479688459431e4830186cc8f74048f797cf7 Mon Sep 17 00:00:00 2001 From: Fenqin Zhou Date: Wed, 11 Nov 2026 08:35:25 +0800 Subject: [PATCH] Validate Homebrew distribution v1.0.95-rc.1 --- Casks/modernize.rb | 17 +++++++++++++++++ Formula/modernize.rb | 27 +++++++++------------------ 2 files changed, 26 insertions(+), 18 deletions(-) create mode 100644 Casks/modernize.rb diff --git a/Casks/modernize.rb b/Casks/modernize.rb new file mode 100644 index 0000000..3492eb9 --- /dev/null +++ b/Casks/modernize.rb @@ -0,0 +1,17 @@ +cask "modernize" do + arch arm: "arm64", intel: "x64" + + version "1.0.95-rc.1" + sha256 arm: "5516691acc6073af51e14e749fed208f56bea63a12300f593dfa647c25b692d2", + intel: "cc52255fb15e63107440ece069f4abc3a0cbf03c8d632edc9150901b7277b7f1" + + url "https://github.com/microsoft/modernize-cli/releases/download/v#{version}/modernize_#{version}_darwin_#{arch}.tar.gz" + name "Modernize" + desc "AI-powered CLI for application modernization" + homepage "https://github.com/microsoft/modernize-cli" + + depends_on formula: "gh" + depends_on :macos + + binary "modernize" +end diff --git a/Formula/modernize.rb b/Formula/modernize.rb index 4dbe9fe..c56baf5 100644 --- a/Formula/modernize.rb +++ b/Formula/modernize.rb @@ -1,27 +1,18 @@ class Modernize < Formula desc "AI-powered CLI for application modernization" homepage "https://github.com/microsoft/modernize-cli" - version "1.0.93" + version "1.0.95-rc.1" - if OS.mac? - if Hardware::CPU.intel? - url "https://github.com/microsoft/modernize-cli/releases/download/v1.0.93/modernize_1.0.93_darwin_x64.tar.gz" - sha256 "82e913a282dcfde15d30011c54bf93b2b0369a929cf88485c51b75f9d40575f7" - elsif Hardware::CPU.arm? - url "https://github.com/microsoft/modernize-cli/releases/download/v1.0.93/modernize_1.0.93_darwin_arm64.tar.gz" - sha256 "7282e0cb4350e74410a7c5a7d2956d4cedbe119ef9fbfa4cafa48857d3e20c96" - end - elsif OS.linux? - if Hardware::CPU.intel? - url "https://github.com/microsoft/modernize-cli/releases/download/v1.0.93/modernize_1.0.93_linux_x64.tar.gz" - sha256 "5ad247208b98b937a772ecec3bb0aa1bb35bda45d63eebf6f0b6e4e2f3105236" - elsif Hardware::CPU.arm? - url "https://github.com/microsoft/modernize-cli/releases/download/v1.0.93/modernize_1.0.93_linux_arm64.tar.gz" - sha256 "8b401854da923d28c0db99a5ffbf82b8cc541de1c210dc0a8da5a7e86f877001" - end + if Hardware::CPU.intel? + url "https://github.com/microsoft/modernize-cli/releases/download/v1.0.95-rc.1/modernize_1.0.95-rc.1_linux_x64.tar.gz" + sha256 "83e4b94a221acab0a7899fdc851e8c87d68e6deb597140181170e3bada57fdf0" + elsif Hardware::CPU.arm? + url "https://github.com/microsoft/modernize-cli/releases/download/v1.0.95-rc.1/modernize_1.0.95-rc.1_linux_arm64.tar.gz" + sha256 "f8b9a7b13ce5b645b8f7fd66d05a757986be9c3102e1eeb7b9c84147eefb2a27" end license "Proprietary" + depends_on :linux depends_on "gh" def install @@ -33,7 +24,7 @@ def install test do version_output = shell_output "#{bin}/modernize --version" assert_equal 0, $CHILD_STATUS.exitstatus - assert_match "modernize", version_output + assert_match version.to_s, version_output end end