You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
viper.SetConfigName("config") // name of config file (without extension)viper.AddConfigPath("/etc/appname/") // path to look for the config file inviper.AddConfigPath("$HOME/.appname") // call multiple times to add many search pathsviper.AddConfigPath(".") // optionally look for config in the working directoryerr:=viper.ReadInConfig() // Find and read the config fileiferr!=nil { // Handle errors reading the config filepanic(fmt.Errorf("Fatal error config file: %s \n", err))
}
I want to use viper that is configuration module.
viper support environment path.
so I modified systemdConfig variable
However Path variable is including file name. not directory.
I want to get only directory path.
The text was updated successfully, but these errors were encountered: