Update README.md

This commit is contained in:
Albert Nigmatzianov 2017-06-09 21:55:21 +02:00 committed by GitHub
parent 99ff9334bd
commit d7cfb13474

View file

@ -323,6 +323,10 @@ func init() {
viper.SetDefault("license", "apache") viper.SetDefault("license", "apache")
} }
func Execute() {
rootCmd.Execute()
}
func main() { func main() {
// Don't forget to read config either from cfgFile or from home directory! // Don't forget to read config either from cfgFile or from home directory!
if cfgFile != "" { if cfgFile != "" {
@ -343,7 +347,7 @@ func main() {
if err := viper.ReadInConfig(); err != nil { if err := viper.ReadInConfig(); err != nil {
fmt.Println("Can't read config:", err) fmt.Println("Can't read config:", err)
os.Exit(1) os.Exit(1)
} }
} }
``` ```