From 344db7027401eca6ed214d7e97eab9a7a7c33b29 Mon Sep 17 00:00:00 2001 From: Ulysses Souza Date: Fri, 2 Oct 2020 19:04:43 +0200 Subject: [PATCH] Fix version command on bypassing to moby cli Signed-off-by: Ulysses Souza --- cli/cmd/version.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cli/cmd/version.go b/cli/cmd/version.go index 0353dcdff..3a50f1790 100644 --- a/cli/cmd/version.go +++ b/cli/cmd/version.go @@ -61,7 +61,10 @@ func runVersion(cmd *cobra.Command, version string) { case formatter.JSON, "{{json.}}": // Try to catch full JSON formats versionString = strings.Replace(getOutFromMoby(cmd, fixedJSONArgs(os.Args[1:])...), `"Version":`, fmt.Sprintf(`"CloudIntegration":%q,"Version":`, displayedVersion), 1) + default: + versionString = getOutFromMoby(cmd) } + fmt.Print(versionString) }