Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cli/named_args: silence package_conflicts_message with --quiet #18330

Merged
merged 1 commit into from
Sep 16, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions Library/Homebrew/cli/named_args.rb
Original file line number Diff line number Diff line change
Expand Up @@ -231,11 +231,13 @@ def load_formula_or_cask(name, only: nil, method: nil, warn: nil)
Failed to load cask: #{name}
#{unreadable_error}
EOS
opoo package_conflicts_message(name, "formula", cask)
opoo package_conflicts_message(name, "formula", cask) unless Context.current.quiet?
end
return formula_or_kegs
elsif cask
opoo package_conflicts_message(name, "cask", formula_or_kegs) if formula_or_kegs
if formula_or_kegs && !Context.current.quiet?
opoo package_conflicts_message(name, "cask", formula_or_kegs)
end
return cask
end
end
Expand Down Expand Up @@ -519,6 +521,7 @@ def warn_if_cask_conflicts(ref, loaded_type)
nil
end
return unless available
return if Context.current.quiet?

opoo package_conflicts_message(ref, loaded_type, cask)
end
Expand Down