From 80be27dc9bb65f6433418e6928a3c178908eb5cd Mon Sep 17 00:00:00 2001 From: Issy Long Date: Sun, 2 Jun 2024 18:48:30 +0100 Subject: [PATCH] Make `brew typecheck --update --suggest-typed` bump strictness further - Not only `false` to `true` but `true` to `strict`. - Only humans every run this, but our goal is to increase the typechecking in our files to get to `strict` everywhere so let's make that easy to remember to do. --- Library/Homebrew/dev-cmd/typecheck.rb | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/Library/Homebrew/dev-cmd/typecheck.rb b/Library/Homebrew/dev-cmd/typecheck.rb index 46fa968a0af99..d87e54bfb2610 100644 --- a/Library/Homebrew/dev-cmd/typecheck.rb +++ b/Library/Homebrew/dev-cmd/typecheck.rb @@ -58,10 +58,12 @@ def run safe_system "bundle", "exec", "parlour" if args.suggest_typed? - ohai "Bumping Sorbet `typed` sigils..." + ohai "Checking if we can bump Sorbet `typed` sigils..." # --sorbet needed because of https://github.com/Shopify/spoom/issues/488 - safe_system "bundle", "exec", "spoom", "srb", "bump", "--dry", "--sorbet", - "#{Gem.bin_path("sorbet", "srb")} tc" + safe_system "bundle", "exec", "spoom", "srb", "bump", "--dry", "--from", "false", "--to", "true", + "--sorbet", "#{Gem.bin_path("sorbet", "srb")} tc" + safe_system "bundle", "exec", "spoom", "srb", "bump", "--dry", "--from", "true", "--to", "strict", + "--sorbet", "#{Gem.bin_path("sorbet", "srb")} tc" end return