You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

30 lines
589 B

package log
type LogCfg struct {
LogConf string `toml:"conf"`
LogPath string `toml:"path"`
LogInfoPath string `toml:"path_info"`
LogErrPath string `toml:"path_err"`
APPName string `toml:"app_name"`
DInfo string
DError string
OutputPaths string
ErrorOutputPaths string
}
type GlobalCfg struct {
Logs LogCfg `toml:"logger"`
}
const (
// ConfigFile is the default configuration file name.
ConfigFile = "./conf/cfg.toml"
)
func New(infoPath, errPath string) LogCfg {
return LogCfg{
LogInfoPath: infoPath,
LogErrPath: errPath,
}
}