Add option in Config to not remove prefix when expanding default values which resolve to other environment variables #103
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hi there!
The latest v1.0.0 version includes breaking changes, among which the fact that a prefix will not be taken into account when expanding a default value that resolves to another environment variable.
I get the rationale, but find it unfortunate that this was a breaking change and the now default behaviour, as it now makes some code very difficult to reuse and inelegant. Of course, it is possible to implement one's own
Lookuper
in place of using those provided by the library, but in the case of highly dynamic configurations, that also makes for convoluted code.I suggest making that optional, so that:
Config
according to the use-case;This is what this PR implements. Also, I took advantage of this PR to fix a few typos here and there in the doc comments.
Tell me what you think! 😄