cmd/root.go
changeset 45 b58a7ea1aeb2
parent 35 61ed03c3f134
child 51 300ac09051a7
--- a/cmd/root.go	Sun Apr 30 20:45:40 2017 +0200
+++ b/cmd/root.go	Sun Apr 30 23:22:09 2017 +0200
@@ -10,6 +10,7 @@
 	"io/ioutil"
 	"os"
 
+	"github.com/pkg/errors"
 	"github.com/spf13/cobra"
 	"github.com/spf13/viper"
 
@@ -146,7 +147,7 @@
 	case "", "plain", "json", "yaml", "template":
 		return nil // Accepted
 	}
-	return fmt.Errorf("output format '%s' not supported", of)
+	return errors.Errorf("output format '%s' not supported", of)
 }
 
 // initConfig reads in config file and ENV variables if set.