Replies: 1 comment 2 replies
-
@alex-kar @duselmann - Do either of you have any ideas on this? |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Currently AndHow has one special configuration parameter that accepts the string
java.io.tmpdir
and replaces it (anywhere in the value and without delimiters) with the actual temp directory. Its a special case and a bit of a hack.I'd like to improve this by adding some type of escape characters / delimiters to make it clear that the text is to be replaced during configuration loading, and extend the concept to any configuration string that wants to use it.
It could be really useful for lots of configuration values to be able to use auto-replacements for a short list of standard system properties, such as:
But, its hard to choose a good escape / delimiter character sequence without colliding with other syntax that might require double escaping in some upstream system. Some possible ideas:
The trick is to pick some type of delimiters that are legal and don't have special meanings in any of the current or potential configuration sources, especially:
Ideally, someone could put a value in like this in a properties file:
MY_SPECIAL_DATABASE_FILE: [[user.home]][[path.separator]]db.export
What would be a good escape sequence delimiter for values?
Beta Was this translation helpful? Give feedback.
All reactions