Skip to content
Myr

Merge pull request #148 from tamird/trailing-spaces

Before adoption: this commit came in with the history the project adopted, so no landing records it.

trim trailing whitespace

authored by Eric Paris · committed by Eric Paris · parents 4b86c66, 5f83d08 · Browse files · 1 file+4 added−6 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+4 added−6 removed

  • other:+4 added−6 removed

1 file+4 added−6 removed

modified:command.go+4 added-6 removed
246 unmodified lines
247248 if c.HasParent() {249 return c.parent.UsageTemplate()250 } else {251 return `{{ $cmd := . }}252Usage: {{if .Runnable}}251 return `{{ $cmd := . }}Usage:{{if .Runnable}}252 {{.UseLine}}{{if .HasFlags}} [flags]{{end}}{{end}}{{if .HasSubCommands}}253 {{ .CommandPath}} [command]{{end}}{{if gt .Aliases 0}}254255Aliases:
2 unmodified lines
258259Examples:260{{ .Example }}{{end}}{{ if .HasAvailableSubCommands}}261263Available Commands: {{range .Commands}}{{if .IsAvailableCommand}}262Available Commands:{{range .Commands}}{{if .IsAvailableCommand}}263 {{rpad .Name .NamePadding }} {{.Short}}{{end}}{{end}}{{end}}{{ if .HasLocalFlags}}264265Flags:266{{.LocalFlags.FlagUsages}}{{end}}{{ if .HasInheritedFlags}}267268Global Flags:269{{.InheritedFlags.FlagUsages}}{{end}}{{if .HasHelpSubCommands}}270272Additional help topics: {{range .Commands}}{{if .IsHelpCommand}}271Additional help topics:{{range .Commands}}{{if .IsHelpCommand}}272 {{rpad .CommandPath .CommandPathPadding}} {{.Short}}{{end}}{{end}}{{end}}{{ if .HasSubCommands }}273274Use "{{.CommandPath}} [command] --help" for more information about a command.275{{end}}`
8 unmodified lines
284 if c.HasParent() {285 return c.parent.HelpTemplate()286 } else {287 return `{{with or .Long .Short }}{{. | trim}}{{end}}289{{if or .Runnable .HasSubCommands}}{{.UsageString}}{{end}}290`288{{if or .Runnable .HasSubCommands}}{{.UsageString}}{{end}}`289 }290}291292// Really only used when casting a command to a commander
815 unmodified lines