3 ms·
Documents should be more open, but please don't push for something data-like (i.e. send the XML proponents off the hill). It's time to make files human-readabl
by makecheck 17y ago
Documents should be more open, but please don't push for something data-like (i.e. send the XML proponents off the hill). It's time to make files human-readable again.
For instance, use something completely plain but deceptively simple, like reStructuredText. This can be parsed or edited by a ton of established tools. It's also easily "diffed". Text formats are also well handled by revision control tools (one of which should be used, publicly, by the editors of these documents). This even achieves the clean markup he desires, because multiple tools can parse .rst files and produce very good HTML out of them.
- RyanMcGreal 17y agoFor human-readable document content, there's nothing wrong with plain old HTML, though formats like RST or markdown are somewhat easier to produce. (I save my blog documents in markdown format - they're just easier to write and update, and I don't have to futz around with JS-heavy WYSIWYG editors.) However, these aren't adequate for structured data that falls outside the scope of a generic print document. For that, I would recommend YAML or JSON over XML, not only because they're human-readable but also because they're far less verbose.
- makecheck 17y agoI'm definitely fine with using data formats for things that really are just raw data (e.g. a series of records with specific fields), and I like JSON too. I just hope that they don't try to chop up something that should be "just a document" into a pile of ugly marked-up containers that make it very hard to see what's even in the document anymore.
- dunham 17y agoContrary to the article, the pdf doesn't appear to be locked in any way. If you run the pdf through "pdftotext -layout", you get a very readable text file which is probably easier to parse than any XML they'd come up with. (Probably easier to deal with than the HTML that Word produces.) If you want to extract metadata or break it into sections to load into your custom web app, it'd be a couple hours work with your favorite scripting language. (Anything with decent regular expression support.) (If you want boldface/italics, I'd recommend tweaking the backend of pdftotext.)