worklog/internal/config/getter.go
2023-01-27 17:11:22 +01:00

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)
}