SetUsageTemplate sets usage template. Can be defined by Application.
(s string)
| 316 | |
| 317 | // SetUsageTemplate sets usage template. Can be defined by Application. |
| 318 | func (c *Command) SetUsageTemplate(s string) { |
| 319 | if s == "" { |
| 320 | c.usageTemplate = nil |
| 321 | return |
| 322 | } |
| 323 | c.usageTemplate = tmpl(s) |
| 324 | } |
| 325 | |
| 326 | // SetFlagErrorFunc sets a function to generate an error when flag parsing |
| 327 | // fails. |