From d8e25b9e6f972f3f9d44a4c33fdd7f07a72cf1b0 Mon Sep 17 00:00:00 2001 From: Andrew Seigner Date: Mon, 24 Jul 2023 19:24:34 +0100 Subject: [PATCH] Fix `linkerd check --output` flag description (#11145) The `linkerd check --output` flag supports 3 formats: `table`, `json`, and `short`. The default `linkerd check` command description incorrectly printed `basic, json, short`. Other extension check commands printed `basic, json`. Modify all check output descriptions to print `table, json, short`. Signed-off-by: Andrew Seigner --- EXTENSIONS.md | 2 +- cli/cmd/check.go | 2 +- jaeger/cmd/check.go | 2 +- multicluster/cmd/check.go | 2 +- viz/cmd/check.go | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/EXTENSIONS.md b/EXTENSIONS.md index 516d971158717..586a937d78cdb 100644 --- a/EXTENSIONS.md +++ b/EXTENSIONS.md @@ -79,7 +79,7 @@ following flags: * `--namespace`/`-n`: Namespace to use for –proxy checks (default: all namespaces) -* `--output`/`-o`: Output format. One of: table, json +* `--output`/`-o`: Output format. One of: table, json, short * `--pre`: Only run pre-installation checks, to determine if the extension can be installed * `--proxy`: Only run data-plane checks, to determine if the data plane is diff --git a/cli/cmd/check.go b/cli/cmd/check.go index f91c88166bf19..5af6548fe5b14 100644 --- a/cli/cmd/check.go +++ b/cli/cmd/check.go @@ -67,7 +67,7 @@ func (options *checkOptions) checkFlagSet() *pflag.FlagSet { flags.StringVar(&options.versionOverride, "expected-version", options.versionOverride, "Overrides the version used when checking if Linkerd is running the latest version (mostly for testing)") flags.StringVar(&options.cliVersionOverride, "cli-version-override", "", "Used to override the version of the cli (mostly for testing)") - flags.StringVarP(&options.output, "output", "o", options.output, "Output format. One of: basic, json, short") + flags.StringVarP(&options.output, "output", "o", options.output, "Output format. One of: table, json, short") flags.DurationVar(&options.wait, "wait", options.wait, "Maximum allowed time for all tests to pass") return flags diff --git a/jaeger/cmd/check.go b/jaeger/cmd/check.go index aa8ab001ba67e..884aff7ee84d8 100644 --- a/jaeger/cmd/check.go +++ b/jaeger/cmd/check.go @@ -180,7 +180,7 @@ code.`, }, } - cmd.Flags().StringVarP(&options.output, "output", "o", options.output, "Output format. One of: basic, json") + cmd.Flags().StringVarP(&options.output, "output", "o", options.output, "Output format. One of: table, json, short") cmd.Flags().DurationVar(&options.wait, "wait", options.wait, "Maximum allowed time for all tests to pass") cmd.Flags().BoolVar(&options.proxy, "proxy", options.proxy, "Also run data-plane checks, to determine if the data plane is healthy") cmd.Flags().StringVarP(&options.namespace, "namespace", "n", options.namespace, "Namespace to use for --proxy checks (default: all namespaces)") diff --git a/multicluster/cmd/check.go b/multicluster/cmd/check.go index 240e0799428c2..deff98f62c345 100644 --- a/multicluster/cmd/check.go +++ b/multicluster/cmd/check.go @@ -105,7 +105,7 @@ non-zero exit code.`, return configureAndRunChecks(stdout, stderr, options) }, } - cmd.Flags().StringVarP(&options.output, "output", "o", options.output, "Output format. One of: basic, json") + cmd.Flags().StringVarP(&options.output, "output", "o", options.output, "Output format. One of: table, json, short") cmd.Flags().DurationVar(&options.wait, "wait", options.wait, "Maximum allowed time for all tests to pass") cmd.Flags().Bool("proxy", false, "") cmd.Flags().MarkHidden("proxy") diff --git a/viz/cmd/check.go b/viz/cmd/check.go index fb9bdd863e776..6bfd1307a25e5 100644 --- a/viz/cmd/check.go +++ b/viz/cmd/check.go @@ -54,7 +54,7 @@ code.`, }, } - cmd.Flags().StringVarP(&options.output, "output", "o", options.output, "Output format. One of: basic, json") + cmd.Flags().StringVarP(&options.output, "output", "o", options.output, "Output format. One of: table, json, short") cmd.Flags().BoolVar(&options.proxy, "proxy", options.proxy, "Also run data-plane checks, to determine if the data plane is healthy") cmd.Flags().DurationVar(&options.wait, "wait", options.wait, "Maximum allowed time for all tests to pass") cmd.Flags().StringVarP(&options.namespace, "namespace", "n", options.namespace, "Namespace to use for --proxy checks (default: all namespaces)")