-
Notifications
You must be signed in to change notification settings - Fork 217
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Config does not support capital letter #26
Comments
The idea is configuration keys should not be case-sensitive. Eg I don't have any tests for that case and its likely I'm not ensuring keys get case folded before they get stored (which would make it impossible to get them out). I'll make sure this works in the upcoming version. |
Fixed on master |
I'm running into this issue with TOML. Per the TOML spec, |
@kdar What version of Config are you using? Latest? https://github.com/mehcode/config-rs/blob/master/src/file/format/toml.rs#L29 That should be definitely be working.
I understand. But this library is not just a TOML parser. There is a great library if you just want to do that: toml-rs. In order to be able to merge configuration properties from N sources we must be case-insensitive. Consider an environment like For similar reasons, the configuration properties are not strongly typed. The source may only allow strings (like the environment) but we want to be able to get a boolean or a Date from it. |
Alright, I'll use toml-rs. Thanks! |
I am using a json file as configuration file, however I can't get correct value with
c.get("Server")
when there are capital letters in the key field, then I found this:I am curious why it design like this, am I missing something.
The text was updated successfully, but these errors were encountered: