News for hackers. Stuff that matters.
Re:Why the fuck are we templating YAML? (2019) by herpdyderp on Tuesday January 23, 2024 @08:13AM (#39102882)
I, on the other hand, find it much harder to read and write even in very simple configs. I never know what the indent is supposed to be, I just press my spacebar until my editor stops complaining. I find it really hard to tell if a line is a new entry or a subset of the parent entry.

I'm sure if I used it more it'd become easier, but my whole team doesn't understand it either. Luckily we only need it for GitHub configurations.

Re:Why the fuck are we templating YAML? (2019) by basil-rash on Tuesday January 23, 2024 @11:18AM (#39105364)
YAML is (vaguely) a superset of JSON, so you can just use JSON (without tabs) and get your life back.

I don’t need a config language with no fewer that 6 subtly different ways of decoding a string to remember, and certainly not one with a spec longer than C’s. Compare to JSON’s, which (famously) fits on a postcard.

https://yaml.org/spec/1.2.2/

https://yaml-multiline.info/

https://www.json.org/json-en.html