41

cross-posted from: https://programming.dev/post/1743099

.yaml, .toml, etc?

you are viewing a single comment's thread
view the rest of the comments
[-] darganon@lemmy.world 5 points 1 year ago

I like xml, but it isn't the easiest to read.

I hate yaml with a burning passion. At least with JSON you can compress it all down.

[-] negativenull@lemmy.world 5 points 1 year ago

If you have a problem, and use XML to solve it, you now have two problems

[-] tony@lemmy.hoyle.me.uk 2 points 1 year ago* (last edited 1 year ago)

A compliant yaml parser will read json, as they're essentially siblings.. so just write your configs in json and they'll work, if you dislike yaml.

[-] darganon@lemmy.world 2 points 1 year ago

Thanks for the tip!

[-] emptyother@programming.dev 1 points 1 year ago

I'm no fan of XML. It looks messy and the schema is difficult to write, imo. XML works best as a markup language.

YAML could have been okay if it were stricter with what they consider strings, and used tabs instead of spaces.

[-] atzanteol@sh.itjust.works 3 points 1 year ago

Using whitespace was a mistake. I know all the kids love it but it's just wrong. I've never had as much difficulty explaining json or xml to users as I have yaml.

[-] schaeferpp@discuss.tchncs.de 0 points 1 year ago* (last edited 1 year ago)

We seem to have something in common: there is a serialisation form, we strongly dislike. But what I cannot understand is: why the heck would anyone torture anyone else to read or even write XML? XML is the absolutely worst configuration language I can imagine. I mean: when is something an attribute, when a tag on its own? What is even a list? And don't forget to include a full HTTP URI for the namespace, otherwise the tag is not defined.

By the way: all valid JSON is valid yaml as well. So in theory, you can use yaml as JSON with comments.

[-] darganon@lemmy.world 1 points 1 year ago

I mainly work with windows, and powershell works great with xml.

this post was submitted on 15 Aug 2023
41 points (95.6% liked)

Technology

59161 readers
2253 users here now

This is a most excellent place for technology news and articles.


Our Rules


  1. Follow the lemmy.world rules.
  2. Only tech related content.
  3. Be excellent to each another!
  4. Mod approved content bots can post up to 10 articles per day.
  5. Threads asking for personal tech support may be deleted.
  6. Politics threads may be removed.
  7. No memes allowed as posts, OK to post as comments.
  8. Only approved bots from the list below, to ask if your bot can be added please contact us.
  9. Check for duplicates before posting, duplicates may be removed

Approved Bots


founded 1 year ago
MODERATORS