YAML is a little eaisier to mess with in a text editor
It's also a little too easy to mess up in a text editor.
Try merging two YAML structures together manually into one file. The only sane way is to load the two fragments in program, merge as desired, and then write it out. It's really, really hard to write valid YAML by hand and sneak it into a program. It's too sensitive to whitespace.
XML, on the other hand, by and large has no problem with whitespace. This allows you to pull of certain quick and nasty hacks to modify element contents without having to worry too much. Not saying that this is a good idea, but something I've had to do from time to time. But a single misplaced space character in a YAML file will render it unloadable. Thus, in my experience, I have come to the opposite conclusion: XML is much more forgiving of manual edits; YAML is brittle and prone to breakage.
These days I view YAML as an opaque serialising mechanism. You look at it, but don't touch it.
• another intruder with the mooring in the heart of the Perl
In reply to Re^7: An Idiot's Guide to YAML
by grinder
in thread An Idiot's Guide to YAML
by scorpio17
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |