mirror of
https://github.com/spf13/viper
synced 2024-12-22 11:37:02 +00:00
feat: experimental logger
Signed-off-by: Mark Sagi-Kazar <mark.sagikazar@gmail.com>
This commit is contained in:
parent
b13f0963f6
commit
5924acc506
1 changed files with 11 additions and 0 deletions
11
experimental_logger.go
Normal file
11
experimental_logger.go
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
//go:build viper_logger
|
||||||
|
// +build viper_logger
|
||||||
|
|
||||||
|
package viper
|
||||||
|
|
||||||
|
// WithLogger sets a custom logger.
|
||||||
|
func WithLogger(l Logger) Option {
|
||||||
|
return optionFunc(func(v *Viper) {
|
||||||
|
v.logger = l
|
||||||
|
})
|
||||||
|
}
|
Loading…
Reference in a new issue