asciidoctor / atom-language-asciidoc

⚛ AsciiDoc language package for the Atom editor.
https://atom.io/packages/language-asciidoc
MIT License
42 stars 20 forks source link

Match literal paragraphs #153

Open mojavelinux opened 8 years ago

mojavelinux commented 8 years ago

Description

The grammar should match literal (i.e., indented) paragraphs. A literal paragraph is a paragraph that begins with one or more spaces. We should only look for spaces at the start of the paragraph, not subsequent lines within the paragraph.

Syntax example

Type the following command:

 $ gem install asciidoctor

Asciidoctor should now be installed on your machine.

The middle line should appear as a literal block. In other words, it's roughly the equivalent of:

Type the following command:

....
$ gem install asciidoctor
....

Asciidoctor should now be installed on your machine.

We might even want to detect literal paragraphs that begin with $ or # followed by a space and highlight them as shell commands. That's just a bonus feature as it's not technically supported in AsciiDoc (yet).

ldez commented 8 years ago

I cannot created the bonus with $ or # because the embedded language doesn't work in this context.

mojavelinux commented 8 years ago

No worries.