lightbend / config

configuration library for JVM languages using HOCON files
https://lightbend.github.io/config/
6.17k stars 966 forks source link

Provide a BNF (or similar) for HOCON #459

Open ogregoire opened 7 years ago

ogregoire commented 7 years ago

HOCON is pretty well explained in HOCON.md.

I couldn't find any formal format description that looks like BNF or similar. I'd like to see such a description to help me create tools in various languages that help validate configuration files before they are fed to applications. I think this validation must happen because HOCON is really human-friendly and humans still make errors from time to time when editing files by hand.

It would therefore be nice that such a BNF, or equivalent, is provided.

havocp commented 7 years ago

I would be happy to have such a thing in the repo, but don't really have the knowledge/time to write it myself. Ideally it could even be validated somehow by the test suite that it accepts/rejects the same files as the implementation.