From efb14a0ec264c4ef408dbbd5330905dd230e979c Mon Sep 17 00:00:00 2001 From: apainintheneck Date: Thu, 9 May 2024 20:14:16 -0700 Subject: [PATCH] fix no autoremove suggestion typo This suggests setting an environment variable that is different than the one we end up checking so I've updated the warning so now things match. If the goal was to have the name in the warning, the environment variable checking logic could be updated. I have no personal preference. ```console $ brew irb ==> Interactive Homebrew Shell Example commands available with: `brew irb --examples` brew(main):001:0> ENV["HOMEBREW_NO_AUTO_REMOVE"] = "1" => "1" brew(main):002:0> Homebrew::EnvConfig.no_autoremove? => false brew(main):003:0> ENV["HOMEBREW_NO_AUTOREMOVE"] = "1" => "1" brew(main):004:0> Homebrew::EnvConfig.no_autoremove? => true ``` --- Library/Homebrew/cleanup.rb | 2 +- Library/Homebrew/cmd/uninstall.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Library/Homebrew/cleanup.rb b/Library/Homebrew/cleanup.rb index d537dfb142..eb3f8728d4 100644 --- a/Library/Homebrew/cleanup.rb +++ b/Library/Homebrew/cleanup.rb @@ -290,7 +290,7 @@ module Homebrew if ENV["HOMEBREW_AUTOREMOVE"].present? opoo "HOMEBREW_AUTOREMOVE is now a no-op as it is the default behaviour. " \ - "Set HOMEBREW_NO_AUTO_REMOVE=1 to disable it." + "Set HOMEBREW_NO_AUTOREMOVE=1 to disable it." end Cleanup.autoremove(dry_run: dry_run?) unless Homebrew::EnvConfig.no_autoremove? diff --git a/Library/Homebrew/cmd/uninstall.rb b/Library/Homebrew/cmd/uninstall.rb index fee34308b9..ff1aafadbc 100644 --- a/Library/Homebrew/cmd/uninstall.rb +++ b/Library/Homebrew/cmd/uninstall.rb @@ -79,7 +79,7 @@ module Homebrew if ENV["HOMEBREW_AUTOREMOVE"].present? opoo "HOMEBREW_AUTOREMOVE is now a no-op as it is the default behaviour. " \ - "Set HOMEBREW_NO_AUTO_REMOVE=1 to disable it." + "Set HOMEBREW_NO_AUTOREMOVE=1 to disable it." end Cleanup.autoremove unless Homebrew::EnvConfig.no_autoremove? end