Skip to content

Ask HN: How should one format plain-text documents?

4 pointsrafael8592 comments
On HN

I would like to store short plain-text documents that are readable as text (without being converted to anything else).

I am familiar with LaTeX and Markdown, but I consider the former to be too unreadable for my purposes (since I don't plan to convert the document to any other format), and the latter to be fairly good, but not quite there. I have heard about org-mode, but I would like a format that works as a stand-alone file, regardless of the editor used.

I am looking at the way that RFC documents are formatted, and I have to say that they are fairly readable, though I couldn't find a specification on their format.

My current solution is something that resembles Markdown, without header markings (because even though they make sense in plain-text, they don't really give a sense of hierarchy structurally), with single blank lines under paragraph headers and double blank lines after the end of a paragraph. Text in a paragraph is limited to 80 characters, and words are not broken.

What are some good ways to denote header hierarchy? Should I indent paragraphs? Should I indent lower levels under a header, so that it's clear when a section ends?

I understand that I have mentioned several subjective preferences, so feel free to add your own subjective opinions.

Comments

Asciidoc looks „natural“

I'm a fan of ReStructuredText. It's not unlike Markdown, but among other things its heading markup is better at conveying hierarchy.

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.