peterbourgon / ff

Flags-first package for configuration

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Option to skip environmental variables

directionless opened this issue · comments

commented

I find that sometimes I want to skip environmental variable parsing. (for example, on windows, where that's a bit odd)

From the code, it looks like using WithEnvVarPrefix("") should behave this way, but it's not documented. (or simply omitting that option)

I think this is a request for a slight bit of doc tweaking. If my understanding is correct, I'm happy to PR it

You have to opt-in to parsing from any source other than commandline flags. So, by default, you don't get any parsing from env vars. I would happily take a PR with doc updates to make this explicit. I guess it should be mentioned in relevant doc comments as well as the README.