Merge pull request #4896 from Benehiko/help-plugin-descriptions

chore: `docker help` should not show plugin vendor and version
This commit is contained in:
Bjorn Neergaard 2024-02-29 07:32:20 -07:00 committed by GitHub
commit 19d02cd101
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 3 additions and 3 deletions

View File

@ -470,7 +470,7 @@ Common Commands:
Management Commands: Management Commands:
{{- range managementSubCommands . }} {{- range managementSubCommands . }}
{{rpad (decoratedName .) (add .NamePadding 1)}}{{.Short}}{{ if isPlugin .}} {{vendorAndVersion .}}{{ end}} {{rpad (decoratedName .) (add .NamePadding 1)}}{{.Short}}
{{- end}} {{- end}}
{{- end}} {{- end}}
@ -479,7 +479,7 @@ Management Commands:
Swarm Commands: Swarm Commands:
{{- range orchestratorSubCommands . }} {{- range orchestratorSubCommands . }}
{{rpad (decoratedName .) (add .NamePadding 1)}}{{.Short}}{{ if isPlugin .}} {{vendorAndVersion .}}{{ end}} {{rpad (decoratedName .) (add .NamePadding 1)}}{{.Short}}
{{- end}} {{- end}}
{{- end}} {{- end}}

View File

@ -35,7 +35,7 @@ func TestGlobalHelp(t *testing.T) {
for _, s := range []string{ for _, s := range []string{
`Management Commands:`, `Management Commands:`,
`\s+container\s+Manage containers`, `\s+container\s+Manage containers`,
`\s+helloworld\*\s+A basic Hello World plugin for tests \(Docker Inc\., testing\)`, `\s+helloworld\*\s+A basic Hello World plugin for tests`,
`\s+image\s+Manage images`, `\s+image\s+Manage images`,
`Commands:`, `Commands:`,
`\s+create\s+Create a new container`, `\s+create\s+Create a new container`,