Re:Systemd Home Directories
by throw0101a on Monday February 10, 2020 @01:23PM
(#22291732)
> I don't think YAML is the least ergonomic configuration format available. It has comments, unlike JSON.
This is because JSON is not a configuration format but a machine-to-machine data exchange format. Using it for configurations is using it for something it was not designed to do.
And comments were left out of JSON on purpose:
> Comments were purposefully excluded from JSON. In 2012, Douglas Crockford described his design decision thus: "I removed comments from JSON because I saw people were using them to hold parsing directives, a practice which would have destroyed interoperability." [27]
This is because JSON is not a configuration format but a machine-to-machine data exchange format. Using it for configurations is using it for something it was not designed to do.
And comments were left out of JSON on purpose:
> Comments were purposefully excluded from JSON. In 2012, Douglas Crockford described his design decision thus: "I removed comments from JSON because I saw people were using them to hold parsing directives, a practice which would have destroyed interoperability." [27]
* https://en.wikipedia.org/wiki/JSON#Data_portability_issues