Suppress usage upon Run error

I changed RunE to Run so that usage wouldn't show upon error. Usage will
still show if PersistentPreRunE fails, which makes sense since those
functions check to make sure arguments passed in are valid.

Also changed logging of multi arg flags to Debugf so that output would
be cleaner.
This commit is contained in:
Priya Wadhwa
2018-09-14 12:15:31 -07:00
parent 14f3c81b79
commit 49d7c7c0ee
2 changed files with 14 additions and 6 deletions
+1 -1
View File
@@ -34,7 +34,7 @@ func (b *multiArg) String() string {
// The second method is Set(value string) error
func (b *multiArg) Set(value string) error {
logrus.Infof("appending to multi args %s", value)
logrus.Debugf("appending to multi args %s", value)
*b = append(*b, value)
return nil
}