@@ -35,7 +35,7 @@ var AppHelpTemplate = `NAME:
3535 {{template "helpNameTemplate" .}}
3636
3737USAGE:
38- {{if .UsageText}}{{wrap .UsageText 3}}{{else}}{{.HelpName}} {{if .VisibleFlags}}[global options]{{end}}{{if .Commands}} command [command options]{{end}} {{if .ArgsUsage}}{{.ArgsUsage}}{{else}}[arguments...]{{end}}{{end}}{{if .Version}}{{if not .HideVersion}}
38+ {{if .UsageText}}{{wrap .UsageText 3}}{{else}}{{.HelpName}} {{if .VisibleFlags}}[global options]{{end}}{{if .Commands}} command [command options]{{end}} {{if .ArgsUsage}}{{.ArgsUsage}}{{else}}{{if .Args}} [arguments...]{{end}} {{end}}{{end}}{{if .Version}}{{if not .HideVersion}}
3939
4040VERSION:
4141 {{.Version}}{{end}}{{end}}{{if .Description}}
@@ -136,7 +136,7 @@ var SubcommandHelpTemplate = `NAME:
136136 {{template "helpNameTemplate" .}}
137137
138138USAGE:
139- {{if .UsageText}}{{wrap .UsageText 3}}{{else}}{{.HelpName}} {{if .VisibleFlags}}command [command options]{{end}} {{if .ArgsUsage}}{{.ArgsUsage}}{{else}}[arguments...]{{end}}{{end}}{{if .Description}}
139+ {{if .UsageText}}{{wrap .UsageText 3}}{{else}}{{.HelpName}} {{if .VisibleFlags}}command [command options]{{end}} {{if .ArgsUsage}}{{.ArgsUsage}}{{else}}{{if .Args}} [arguments...]{{end}} {{end}}{{end}}{{if .Description}}
140140
141141DESCRIPTION:
142142 {{template "descriptionTemplate" .}}{{end}}{{if .VisibleCommands}}
@@ -253,6 +253,8 @@ type App struct {
253253 Usage string
254254 // Text to override the USAGE section of help
255255 UsageText string
256+ // Whether this command supports arguments
257+ Args bool
256258 // Description of the program argument format.
257259 ArgsUsage string
258260 // Version of the program
@@ -523,6 +525,8 @@ type Command struct {
523525 UsageText string
524526 // A longer explanation of how the command works
525527 Description string
528+ // Whether this command supports arguments
529+ Args bool
526530 // A short description of the arguments of this command
527531 ArgsUsage string
528532 // The category the command is part of
0 commit comments