32 lines
517 B
Go
32 lines
517 B
Go
package config
|
|
|
|
import "github.com/spf13/viper"
|
|
|
|
// exported function(s)
|
|
func Database() string {
|
|
return viper.GetString(database)
|
|
}
|
|
|
|
func ServerListen() string {
|
|
return viper.GetString(serverListen)
|
|
}
|
|
|
|
func ServerPort() int {
|
|
return viper.GetInt(serverPort)
|
|
}
|
|
|
|
func ReportHeaders() []string {
|
|
return viper.GetStringSlice(reportHeaders)
|
|
}
|
|
|
|
func Help() bool {
|
|
return viper.GetBool(help)
|
|
}
|
|
|
|
func Debug() bool {
|
|
return viper.GetBool(debug)
|
|
}
|
|
|
|
func GetString(value string) string {
|
|
return viper.GetString(value)
|
|
}
|