1
0
mirror of https://github.com/writeas/writeas-cli synced 2025-07-26 23:08:16 +00:00

Improve subcommand help template

Shows 'writeas' instead of generic 'command'
This commit is contained in:
Matt Baer 2015-09-01 10:51:07 -04:00
parent 995d73db91
commit 80d0f76532

View File

@ -171,6 +171,20 @@ func main() {
},
}
cli.CommandHelpTemplate = `NAME:
{{.Name}} - {{.Usage}}
USAGE:
writeas {{.Name}}{{if .Flags}} [command options]{{end}} [arguments...]{{if .Description}}
DESCRIPTION:
{{.Description}}{{end}}{{if .Flags}}
OPTIONS:
{{range .Flags}}{{.}}
{{end}}{{ end }}
`
app.Run(os.Args)
}