From cdabba3cb5b8ffa8660b97f0c39eaa2a6b045199 Mon Sep 17 00:00:00 2001 From: Parham Alvani Date: Wed, 27 Dec 2023 05:52:19 +0000 Subject: [PATCH] revert: add prefix for koanf into the readme again --- README.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index a48eafa..d8450a3 100644 --- a/README.md +++ b/README.md @@ -21,7 +21,8 @@ cfg := koanf.Provide("testing", Config{ ``` You can pass the default values by passing an instance of the `Config` and fill it with default values. -Use `__` in the environment variables to replace `.`, for example use `RABBITMQ__SERVICE` to reference `Config.RabbitMQ.Service`. +Environment variables should be prefixed by service name to be considered. For example for the `testing` +service you need to use `TESTING_RABBITMQ__SERVICE` to reference `Config.RabbitMQ.Service`. Please note that to use `koanf` you need to tag your structure by `koanf` and set the name for configuration as follows: