From 508c160462d1d8606631dd3bba6fd1198dd74cdd Mon Sep 17 00:00:00 2001 From: Sebastiaan van Stijn Date: Thu, 12 Jul 2018 01:34:34 +0200 Subject: [PATCH] Adapt min-column width to component information Signed-off-by: Sebastiaan van Stijn Upstream-commit: 0f7ae34ea9c9401a109640c2847756ff32e772bd Component: cli --- .../testdata/docker-client-version.golden | 66 +++++++++---------- components/cli/cli/command/system/version.go | 2 +- 2 files changed, 34 insertions(+), 34 deletions(-) diff --git a/components/cli/cli/command/system/testdata/docker-client-version.golden b/components/cli/cli/command/system/testdata/docker-client-version.golden index 414b7176a0..04cc88a66f 100644 --- a/components/cli/cli/command/system/testdata/docker-client-version.golden +++ b/components/cli/cli/command/system/testdata/docker-client-version.golden @@ -1,42 +1,42 @@ Client: - Version: 18.99.5-ce - API version: 1.38 - Go version: go1.10.2 - Git commit: deadbeef - Built: Wed May 30 22:21:05 2018 - OS/Arch: linux/amd64 - Experimental: true + Version: 18.99.5-ce + API version: 1.38 + Go version: go1.10.2 + Git commit: deadbeef + Built: Wed May 30 22:21:05 2018 + OS/Arch: linux/amd64 + Experimental: true Server: Docker Enterprise Edition (EE) 2.0 Engine: - Version: 17.06.2-ee-15 - API version: 1.30 (minimum version 1.12) - Go version: go1.8.7 - Git commit: 64ddfa6 - Built: Mon Jul 9 23:38:38 2018 - OS/Arch: linux/amd64 - Experimental: false + Version: 17.06.2-ee-15 + API version: 1.30 (minimum version 1.12) + Go version: go1.8.7 + Git commit: 64ddfa6 + Built: Mon Jul 9 23:38:38 2018 + OS/Arch: linux/amd64 + Experimental: false Universal Control Plane: - Version: 17.06.2-ee-15 - ApiVersion: 1.30 - Arch: amd64 - BuildTime: Mon Jul 2 21:24:07 UTC 2018 - GitCommit: 4513922 - GoVersion: go1.9.4 - MinApiVersion: 1.20 - Os: linux - Version: 3.0.3-tp2 + Version: 17.06.2-ee-15 + ApiVersion: 1.30 + Arch: amd64 + BuildTime: Mon Jul 2 21:24:07 UTC 2018 + GitCommit: 4513922 + GoVersion: go1.9.4 + MinApiVersion: 1.20 + Os: linux + Version: 3.0.3-tp2 Kubernetes: - Version: 1.8+ - buildDate: 2018-04-26T16:51:21Z - compiler: gc - gitCommit: 8d637aedf46b9c21dde723e29c645b9f27106fa5 - gitTreeState: clean - gitVersion: v1.8.11-docker-8d637ae - goVersion: go1.8.3 - major: 1 - minor: 8+ - platform: linux/amd64 + Version: 1.8+ + buildDate: 2018-04-26T16:51:21Z + compiler: gc + gitCommit: 8d637aedf46b9c21dde723e29c645b9f27106fa5 + gitTreeState: clean + gitVersion: v1.8.11-docker-8d637ae + goVersion: go1.8.3 + major: 1 + minor: 8+ + platform: linux/amd64 Calico: Version: v3.0.8 cni: v2.0.6 diff --git a/components/cli/cli/command/system/version.go b/components/cli/cli/command/system/version.go index 2a8fa5e599..7593b11b81 100644 --- a/components/cli/cli/command/system/version.go +++ b/components/cli/cli/command/system/version.go @@ -204,7 +204,7 @@ func runVersion(dockerCli command.Cli, opts *versionOptions) error { } func prettyPrintVersion(dockerCli command.Cli, vd versionInfo, tmpl *template.Template) error { - t := tabwriter.NewWriter(dockerCli.Out(), 15, 1, 1, ' ', 0) + t := tabwriter.NewWriter(dockerCli.Out(), 20, 1, 1, ' ', 0) err := tmpl.Execute(t, vd) t.Write([]byte("\n")) t.Flush()