Skip to content

Commit 1546d71

Browse files
Merge pull request #1098 from dhiltgen/long_help
Show long help message when defined
2 parents deb84a9 + 375d9a4 commit 1546d71

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

cli/cobra.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ var usageTemplate = `Usage:
104104
{{- if not .HasSubCommands}} {{.UseLine}}{{end}}
105105
{{- if .HasSubCommands}} {{ .CommandPath}}{{- if .HasAvailableFlags}} [OPTIONS]{{end}} COMMAND{{end}}
106106
107-
{{ .Short | trim }}
107+
{{if ne .Long ""}}{{ .Long | trim }}{{ else }}{{ .Short | trim }}{{end}}
108108
109109
{{- if gt .Aliases 0}}
110110

0 commit comments

Comments
 (0)