mirror of
https://github.com/spf13/viper
synced 2024-12-23 12:07:02 +00:00
Add a note in the README.md for usage of CancelWatchConfig()
This commit is contained in:
parent
981de21183
commit
bab97b4ec3
1 changed files with 3 additions and 0 deletions
|
@ -123,6 +123,9 @@ viper.OnConfigChange(func(e fsnotify.Event) {
|
||||||
})
|
})
|
||||||
```
|
```
|
||||||
|
|
||||||
|
If you wish to stop watching the configPaths, simply call viper.CancelWatchConfig().
|
||||||
|
Note: This might be necessary if your tests involve trying out various config files.
|
||||||
|
|
||||||
### Reading Config from io.Reader
|
### Reading Config from io.Reader
|
||||||
|
|
||||||
Viper predefines many configuration sources such as files, environment
|
Viper predefines many configuration sources such as files, environment
|
||||||
|
|
Loading…
Reference in a new issue