3 ms·
I'm with douche. If your config is so complicated you need variable substitution and regex then it's no-longer config: it's a driver program. Might as well prog
by m-j-fox 9y ago
I'm with douche. If your config is so complicated you need variable substitution and regex then it's no-longer config: it's a driver program. Might as well program in a programming language.
- sevensor 9y agoSo, when I first learned about YAML, I thought it was a great idea. I was wrong. I've been burned too many times by ambiguity. Config file formats should have a grammar that fits on a sheet of paper. Maybe two sheets.
- hp 9y agoI think this is reasonable in some contexts but it depends. Often the configuration is done by a different person or in a different context than the development. The configure-er may or may not be a programmer and the deployment environment may or may not have xyz programming language available, etc. The JSON superset aspect nicely supports spitting out JSON from a script when people want to do it that way. HOCON is nice when for example you just want to sub in a couple of env variables or avoid a little cut-and-paste.