Commit e35f8f50 authored by Evan Read's avatar Evan Read

Highlight Asciidoc as plaintext

parent c869de6b
...@@ -10,14 +10,14 @@ You can find the full documentation for the AsciiDoc syntax at <https://asciidoc ...@@ -10,14 +10,14 @@ You can find the full documentation for the AsciiDoc syntax at <https://asciidoc
### Paragraphs ### Paragraphs
```asciidoc ```plaintext
A normal paragraph. A normal paragraph.
Line breaks are not preserved. Line breaks are not preserved.
``` ```
Line comments, which are lines that start with `//`, are skipped: Line comments, which are lines that start with `//`, are skipped:
```asciidoc ```plaintext
// this is a comment // this is a comment
``` ```
...@@ -25,7 +25,7 @@ A blank line separates paragraphs. ...@@ -25,7 +25,7 @@ A blank line separates paragraphs.
A paragraph with the `[%hardbreaks]` option will preserve line breaks: A paragraph with the `[%hardbreaks]` option will preserve line breaks:
```asciidoc ```plaintext
[%hardbreaks] [%hardbreaks]
This paragraph carries the `hardbreaks` option. This paragraph carries the `hardbreaks` option.
Notice how line breaks are now preserved. Notice how line breaks are now preserved.
...@@ -35,7 +35,7 @@ An indented (literal) paragraph disables text formatting, ...@@ -35,7 +35,7 @@ An indented (literal) paragraph disables text formatting,
preserves spaces and line breaks, and is displayed in a preserves spaces and line breaks, and is displayed in a
monospaced font: monospaced font:
```asciidoc ```plaintext
This literal paragraph is indented with one space. This literal paragraph is indented with one space.
As a consequence, *text formatting*, spaces, As a consequence, *text formatting*, spaces,
and lines breaks will be preserved. and lines breaks will be preserved.
...@@ -43,7 +43,7 @@ monospaced font: ...@@ -43,7 +43,7 @@ monospaced font:
An admonition paragraph grabs the reader's attention: An admonition paragraph grabs the reader's attention:
```asciidoc ```plaintext
NOTE: This is a brief reference, please read the full documentation at https://asciidoctor.org/docs/. NOTE: This is a brief reference, please read the full documentation at https://asciidoctor.org/docs/.
TIP: Lists can be indented. Leading whitespace is not significant. TIP: Lists can be indented. Leading whitespace is not significant.
...@@ -53,7 +53,7 @@ TIP: Lists can be indented. Leading whitespace is not significant. ...@@ -53,7 +53,7 @@ TIP: Lists can be indented. Leading whitespace is not significant.
**Constrained (applied at word boundaries)** **Constrained (applied at word boundaries)**
```asciidoc ```plaintext
*strong importance* (aka bold) *strong importance* (aka bold)
_stress emphasis_ (aka italic) _stress emphasis_ (aka italic)
`monospaced` (aka typewriter text) `monospaced` (aka typewriter text)
...@@ -64,7 +64,7 @@ _stress emphasis_ (aka italic) ...@@ -64,7 +64,7 @@ _stress emphasis_ (aka italic)
**Unconstrained (applied anywhere)** **Unconstrained (applied anywhere)**
```asciidoc ```plaintext
**C**reate+**R**ead+**U**pdate+**D**elete **C**reate+**R**ead+**U**pdate+**D**elete
fan__freakin__tastic fan__freakin__tastic
``mono``culture ``mono``culture
...@@ -72,7 +72,7 @@ fan__freakin__tastic ...@@ -72,7 +72,7 @@ fan__freakin__tastic
**Replacements** **Replacements**
```asciidoc ```plaintext
A long time ago in a galaxy far, far away... A long time ago in a galaxy far, far away...
(C) 1976 Arty Artisan (C) 1976 Arty Artisan
I believe I shall--no, actually I won't. I believe I shall--no, actually I won't.
...@@ -80,7 +80,7 @@ I believe I shall--no, actually I won't. ...@@ -80,7 +80,7 @@ I believe I shall--no, actually I won't.
**Macros** **Macros**
```asciidoc ```plaintext
// where c=specialchars, q=quotes, a=attributes, r=replacements, m=macros, p=post_replacements, etc. // where c=specialchars, q=quotes, a=attributes, r=replacements, m=macros, p=post_replacements, etc.
The European icon:flag[role=blue] is blue & contains pass:[************] arranged in a icon:circle-o[role=yellow]. The European icon:flag[role=blue] is blue & contains pass:[************] arranged in a icon:circle-o[role=yellow].
The pass:c[->] operator is often referred to as the stabby lambda. The pass:c[->] operator is often referred to as the stabby lambda.
...@@ -93,12 +93,12 @@ stem:[sqrt(4) = 2] ...@@ -93,12 +93,12 @@ stem:[sqrt(4) = 2]
**User-defined attributes** **User-defined attributes**
```asciidoc ```plaintext
// define attributes in the document header // define attributes in the document header
:name: value :name: value
``` ```
```asciidoc ```plaintext
:url-gem: https://rubygems.org/gems/asciidoctor :url-gem: https://rubygems.org/gems/asciidoctor
You can download and install Asciidoctor {asciidoctor-version} from {url-gem}. You can download and install Asciidoctor {asciidoctor-version} from {url-gem}.
...@@ -117,7 +117,7 @@ GitLab sets the following environment attributes: ...@@ -117,7 +117,7 @@ GitLab sets the following environment attributes:
### Links ### Links
```asciidoc ```plaintext
https://example.org/page[A webpage] https://example.org/page[A webpage]
link:../path/to/file.txt[A local file] link:../path/to/file.txt[A local file]
xref:document.adoc[A sibling document] xref:document.adoc[A sibling document]
...@@ -126,7 +126,7 @@ mailto:hello@example.org[Email to say hello!] ...@@ -126,7 +126,7 @@ mailto:hello@example.org[Email to say hello!]
### Anchors ### Anchors
```asciidoc ```plaintext
[[idname,reference text]] [[idname,reference text]]
// or written using normal block attributes as `[#idname,reftext=reference text]` // or written using normal block attributes as `[#idname,reftext=reference text]`
A paragraph (or any block) with an anchor (aka ID) and reftext. A paragraph (or any block) with an anchor (aka ID) and reftext.
...@@ -142,7 +142,7 @@ This paragraph has a footnote.footnote:[This is the text of the footnote.] ...@@ -142,7 +142,7 @@ This paragraph has a footnote.footnote:[This is the text of the footnote.]
#### Unordered #### Unordered
```asciidoc ```plaintext
* level 1 * level 1
** level 2 ** level 2
*** level 3 *** level 3
...@@ -161,7 +161,7 @@ Attach a block or paragraph to a list item using a list continuation (which you ...@@ -161,7 +161,7 @@ Attach a block or paragraph to a list item using a list continuation (which you
#### Ordered #### Ordered
```asciidoc ```plaintext
. Step 1 . Step 1
. Step 2 . Step 2
.. Step 2a .. Step 2a
...@@ -177,14 +177,14 @@ Attach a block or paragraph to a list item using a list continuation (which you ...@@ -177,14 +177,14 @@ Attach a block or paragraph to a list item using a list continuation (which you
#### Checklist #### Checklist
```asciidoc ```plaintext
* [x] checked * [x] checked
* [ ] not checked * [ ] not checked
``` ```
#### Callout #### Callout
```asciidoc ```plaintext
// enable callout bubbles by adding `:icons: font` to the document header // enable callout bubbles by adding `:icons: font` to the document header
[,ruby] [,ruby]
---- ----
...@@ -195,7 +195,7 @@ puts 'Hello, World!' # <1> ...@@ -195,7 +195,7 @@ puts 'Hello, World!' # <1>
#### Description #### Description
```asciidoc ```plaintext
first term:: description of first term first term:: description of first term
second term:: second term::
description of second term description of second term
...@@ -205,7 +205,7 @@ description of second term ...@@ -205,7 +205,7 @@ description of second term
#### Header #### Header
```asciidoc ```plaintext
= Document Title = Document Title
Author Name <author@example.org> Author Name <author@example.org>
v1.0, 2019-01-01 v1.0, 2019-01-01
...@@ -213,7 +213,7 @@ v1.0, 2019-01-01 ...@@ -213,7 +213,7 @@ v1.0, 2019-01-01
#### Sections #### Sections
```asciidoc ```plaintext
= Document Title (Level 0) = Document Title (Level 0)
== Level 1 == Level 1
=== Level 2 === Level 2
...@@ -225,7 +225,7 @@ v1.0, 2019-01-01 ...@@ -225,7 +225,7 @@ v1.0, 2019-01-01
#### Includes #### Includes
```asciidoc ```plaintext
include::basics.adoc[] include::basics.adoc[]
// define -a allow-uri-read to allow content to be read from URI // define -a allow-uri-read to allow content to be read from URI
...@@ -239,13 +239,13 @@ included, a number that is inclusive of transitive dependencies. ...@@ -239,13 +239,13 @@ included, a number that is inclusive of transitive dependencies.
### Blocks ### Blocks
```asciidoc ```plaintext
-- --
open - a general-purpose content wrapper; useful for enclosing content to attach to a list item open - a general-purpose content wrapper; useful for enclosing content to attach to a list item
-- --
``` ```
```asciidoc ```plaintext
// recognized types include CAUTION, IMPORTANT, NOTE, TIP, and WARNING // recognized types include CAUTION, IMPORTANT, NOTE, TIP, and WARNING
// enable admonition icons by setting `:icons: font` in the document header // enable admonition icons by setting `:icons: font` in the document header
[NOTE] [NOTE]
...@@ -254,13 +254,13 @@ admonition - a notice for the reader, ranging in severity from a tip to an alert ...@@ -254,13 +254,13 @@ admonition - a notice for the reader, ranging in severity from a tip to an alert
==== ====
``` ```
```asciidoc ```plaintext
==== ====
example - a demonstration of the concept being documented example - a demonstration of the concept being documented
==== ====
``` ```
```asciidoc ```plaintext
.Toggle Me .Toggle Me
[%collapsible] [%collapsible]
==== ====
...@@ -268,58 +268,58 @@ collapsible - these details are revealed by clicking the title ...@@ -268,58 +268,58 @@ collapsible - these details are revealed by clicking the title
==== ====
``` ```
```asciidoc ```plaintext
**** ****
sidebar - auxiliary content that can be read independently of the main content sidebar - auxiliary content that can be read independently of the main content
**** ****
``` ```
```asciidoc ```plaintext
.... ....
literal - an exhibit that features program output literal - an exhibit that features program output
.... ....
``` ```
```asciidoc ```plaintext
---- ----
listing - an exhibit that features program input, source code, or the contents of a file listing - an exhibit that features program input, source code, or the contents of a file
---- ----
``` ```
```asciidoc ```plaintext
[,language] [,language]
---- ----
source - a listing that is embellished with (colorized) syntax highlighting source - a listing that is embellished with (colorized) syntax highlighting
---- ----
``` ```
````asciidoc ````plaintext
\```language \```language
fenced code - a shorthand syntax for the source block fenced code - a shorthand syntax for the source block
\``` \```
```` ````
```asciidoc ```plaintext
[,attribution,citetitle] [,attribution,citetitle]
____ ____
quote - a quotation or excerpt; attribution with title of source are optional quote - a quotation or excerpt; attribution with title of source are optional
____ ____
``` ```
```asciidoc ```plaintext
[verse,attribution,citetitle] [verse,attribution,citetitle]
____ ____
verse - a literary excerpt, often a poem; attribution with title of source are optional verse - a literary excerpt, often a poem; attribution with title of source are optional
____ ____
``` ```
```asciidoc ```plaintext
++++ ++++
pass - content passed directly to the output document; often raw HTML pass - content passed directly to the output document; often raw HTML
++++ ++++
``` ```
```asciidoc ```plaintext
// activate stem support by adding `:stem:` to the document header // activate stem support by adding `:stem:` to the document header
[stem] [stem]
++++ ++++
...@@ -327,7 +327,7 @@ x = y^2 ...@@ -327,7 +327,7 @@ x = y^2
++++ ++++
``` ```
```asciidoc ```plaintext
//// ////
comment - content which is not included in the output document comment - content which is not included in the output document
//// ////
...@@ -335,7 +335,7 @@ comment - content which is not included in the output document ...@@ -335,7 +335,7 @@ comment - content which is not included in the output document
### Tables ### Tables
```asciidoc ```plaintext
.Table Attributes .Table Attributes
[cols=>1h;2d,width=50%,frame=topbot] [cols=>1h;2d,width=50%,frame=topbot]
|=== |===
...@@ -366,7 +366,7 @@ comment - content which is not included in the output document ...@@ -366,7 +366,7 @@ comment - content which is not included in the output document
### Multimedia ### Multimedia
```asciidoc ```plaintext
image::screenshot.png[block image,800,450] image::screenshot.png[block image,800,450]
Press image:reload.svg[reload,16,opts=interactive] to reload the page. Press image:reload.svg[reload,16,opts=interactive] to reload the page.
...@@ -380,12 +380,12 @@ video::300817511[vimeo] ...@@ -380,12 +380,12 @@ video::300817511[vimeo]
### Breaks ### Breaks
```asciidoc ```plaintext
// thematic break (aka horizontal rule) // thematic break (aka horizontal rule)
--- ---
``` ```
```asciidoc ```plaintext
// page break // page break
<<< <<<
``` ```
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment