Cleanup various TODOs

These were also easily fixed, already fixed or incorrect and
non-controversial.

Co-authored-by: Issy Long <issyl0@github.com>
This commit is contained in:
Mike McQuaid 2023-09-01 19:22:25 +01:00
parent e7d0625776
commit f73607553c
No known key found for this signature in database
GPG Key ID: 3338A31AFDB1D829
3 changed files with 14 additions and 8 deletions

View File

@ -164,7 +164,6 @@ Naming/HeredocDelimiterNaming:
Naming/InclusiveLanguage:
CheckStrings: true
FlaggedTerms:
# TODO: If possible, make this stricter.
slave:
AllowedRegex:
- "gitslave" # Used in formula `gitslave`
@ -392,12 +391,12 @@ Style/NumericLiterals:
Exclude:
- "**/Brewfile"
# TODO: These are pre-existing violations and should be corrected
# to define methods so that call sites can be type-checked.
Style/OpenStructUse:
Exclude:
- "Homebrew/cli/args.rb"
- "Taps/**/*.rb"
# TODO: This is a pre-existing violation and should be corrected
# to define methods so that call sites can be type-checked.
- "Homebrew/cli/args.rb"
# Rescuing `StandardError` is an understood default.
Style/RescueStandardError:

View File

@ -116,7 +116,6 @@ module Homebrew
begin
formula.clear_cache if args.force?
# TODO: Deprecate `--bottle-tag`.
bottle_tag = if (bottle_tag = args.bottle_tag&.to_sym)
Utils::Bottles::Tag.from_symbol(bottle_tag)
else

View File

@ -74,14 +74,22 @@ class AbstractDownloadStrategy
# Disable any output during downloading.
#
# TODO: Deprecate once we have an explicitly documented alternative.
#
# @api public
sig { void }
def shutup!
def quiet!
@quiet = true
end
# Disable any output during downloading.
#
# @deprecated
# @api private
sig { void }
def shutup!
# odeprecated "AbstractDownloadStrategy#shutup!", "AbstractDownloadStrategy#quiet!"
quiet!
end
def quiet?
Context.current.quiet? || @quiet
end