a8m / envsubst

Environment variables substitution for Go
MIT License
747 stars 83 forks source link

Add option to only parse $ALL_CAPS env vars #32

Open vladnosek opened 3 years ago

vladnosek commented 3 years ago

Especially for nginx configs, lots of directives use $lowercase_variable, so having to escape a lot of content.

It would be nice to have an caps-only flag to only detect env vars that are uppercase.

dnitsch commented 3 years ago

I could jump on this if there are no other takers for a PR on this.

@a8m the only thing I guess is to settle on the bool flag name --no-lower maybe?

a8m commented 3 years ago

Hey @dnitsch and @vladnosek, I'm fine with adding this option (including the new flag). Please feel free to send a PR and tag me there. Thanks 🙏