Closed dev-davexoyinbo closed 11 months ago
This crate does not feature functionality to load .env
files, just as it does not feature functionality to interpolate environment variables (which I answered in https://github.com/mehcode/config-rs/issues/447#issuecomment-1666865128 already).
Also, such functionality is not planned. Use a crate like handlebars to interpolate into your configuration files! For reading .env
files, I don't know whether there's a crate for that out there (I never used .env
files myself, so I don't even know what format it uses).
Yes, thank you. I used handlebars and it now works
https://github.com/mehcode/config-rs/issues/447#issuecomment-1666885398
Using the Environment struct doesn't load environment variables in .env file
Or is there a way to only load the .env file?