Merge pull request #206 from rabbitmq/rabbitmq-cli-205
Supress banner for machine readable formats
This commit is contained in:
commit
e37179830b
|
|
@ -209,10 +209,17 @@ defmodule RabbitMQCtl do
|
|||
end
|
||||
end
|
||||
|
||||
## Suppress banner if --quiet option is provided
|
||||
# Suppress banner if --quiet option is provided
|
||||
defp maybe_print_banner(_, _, %{quiet: true}) do
|
||||
nil
|
||||
end
|
||||
# Suppress banner if a machine-readable formatter is used
|
||||
defp maybe_print_banner(_, _, %{formatter: "csv"}) do
|
||||
nil
|
||||
end
|
||||
defp maybe_print_banner(_, _, %{formatter: "json"}) do
|
||||
nil
|
||||
end
|
||||
defp maybe_print_banner(command, args, opts) do
|
||||
case command.banner(args, opts) do
|
||||
nil -> nil
|
||||
|
|
|
|||
Loading…
Reference in New Issue