maliceio / malice

VirusTotal Wanna Be - Now with 100% more Hipster
Apache License 2.0
1.65k stars 265 forks source link

handle bad flags #23

Closed blacktop closed 8 years ago

blacktop commented 8 years ago
❯❯❯ go run main.go plugin list -d -a                                                                                                            
Incorrect Usage.

Usage: malice list [OPTIONS] [arg...]
list enabled installed plugins

Options:

   --all    display all installed plugins
   --detail, -d display plugin details
ERRO[0000] "flag provided but not defined: -a"
goroutine 1 [running]:
github.com/maliceio/malice/malice/errors.CheckErrorWithMessage(0x4846100, 0xc42032dad0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x4578ac0)
    /Users/me/src/go/src/github.com/maliceio/malice/malice/errors/errors.go:24 +0x90
github.com/maliceio/malice/malice/errors.CheckError(0x4846100, 0xc42032dad0, 0x5)
    /Users/me/src/go/src/github.com/maliceio/malice/malice/errors/errors.go:12 +0x62
main.main()
    /Users/me/src/go/src/github.com/maliceio/malice/main.go:81 +0x40d