Configuration icon indicating copy to clipboard operation
Configuration copied to clipboard

Maintain type when overriding values via env var and argv

Open youming-lin opened this issue 7 years ago • 2 comments

Env var and argv will assign non-JSON, non-PLIST to String type, always. This makes overriding numeric values with numeric values impossible. We should figure out a way to coerce the string values from env var and argv into the correct types.

youming-lin avatar Apr 06 '17 21:04 youming-lin

I have also run into this issue, it's also a problem for e.g. boolean values.

Fryie avatar Nov 13 '19 18:11 Fryie

A "workaround" is to instead supply a JSON dictionary for the parent key with the property to override as a single key. I believe, the library will then merge this dictionary with the dictionary for the parent key derived from other sources.

Fryie avatar Feb 10 '20 17:02 Fryie