mirror of
https://github.com/rwxrob/bonzai
synced 2024-11-18 15:25:45 +00:00
Fix minor UsageError bug
This commit is contained in:
parent
cf1e15abff
commit
7508d7bf9b
3
cmd.go
3
cmd.go
@ -113,8 +113,9 @@ func (x *Cmd) Run() {
|
|||||||
Exit()
|
Exit()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// UsageError returns an error with a single-line usage string.
|
||||||
func (x *Cmd) UsageError() error {
|
func (x *Cmd) UsageError() error {
|
||||||
return fmt.Sprintf("usage: %v %v\n", x.Name, x.Usage)
|
return fmt.Errorf("usage: %v %v\n", x.Name, x.Usage)
|
||||||
}
|
}
|
||||||
|
|
||||||
// Add creates a new Cmd and sets the name and aliases and adds to
|
// Add creates a new Cmd and sets the name and aliases and adds to
|
||||||
|
Loading…
Reference in New Issue
Block a user