mirror of
https://github.com/He4eT/oddsquat.git
synced 2026-05-04 20:37:22 +00:00
md-test: update
This commit is contained in:
parent
ca00dcd0b5
commit
96a1b486f3
1 changed files with 53 additions and 53 deletions
|
|
@ -25,7 +25,7 @@ filters — including [Setext](http://docutils.sourceforge.net/mirror/setext.htm
|
||||||
[Grutatext](http://www.triptico.com/software/grutatxt.html), and [EtText](http://ettext.taint.org/doc/) — the single biggest source of
|
[Grutatext](http://www.triptico.com/software/grutatxt.html), and [EtText](http://ettext.taint.org/doc/) — the single biggest source of
|
||||||
inspiration for Markdown's syntax is the format of plain text email.
|
inspiration for Markdown's syntax is the format of plain text email.
|
||||||
|
|
||||||
**Note:** This document is itself written using Markdown
|
**Note:** This document is itself written using Markdown.
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
|
|
@ -43,7 +43,6 @@ inspiration for Markdown's syntax is the format of plain text email.
|
||||||
* [Emphasis](#emphasis)
|
* [Emphasis](#emphasis)
|
||||||
* [Code](#code)
|
* [Code](#code)
|
||||||
|
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
## Block Elements
|
## Block Elements
|
||||||
|
|
@ -66,14 +65,9 @@ end a line with two or more spaces, then type return.
|
||||||
|
|
||||||
### Headers
|
### Headers
|
||||||
|
|
||||||
Markdown supports two styles of headers, [Setext] [1] and [atx] [2].
|
Headers are lines that start with the `#` symbol.
|
||||||
|
The number of characters defines the header level,
|
||||||
Optionally, you may "close" atx-style headers. This is purely
|
from one (`#`) for `<h1>` to six (`######`) for `<h6>`.
|
||||||
cosmetic — you can use this if you think it looks better. The
|
|
||||||
closing hashes don't even need to match the number of hashes
|
|
||||||
used to open the header. (The number of opening hashes
|
|
||||||
determines the header level.)
|
|
||||||
|
|
||||||
|
|
||||||
### Blockquotes
|
### Blockquotes
|
||||||
|
|
||||||
|
|
@ -111,20 +105,20 @@ adding additional levels of `>`:
|
||||||
Blockquotes can contain other Markdown elements, including headers, lists,
|
Blockquotes can contain other Markdown elements, including headers, lists,
|
||||||
and code blocks:
|
and code blocks:
|
||||||
|
|
||||||
> ## This is a header.
|
> ### Here's a list
|
||||||
>
|
>
|
||||||
> 1. This is the first list item.
|
> 1. This is the first list item.
|
||||||
> 2. This is the second list item.
|
> 2. This is the second list item.
|
||||||
>
|
>
|
||||||
> Here's some example code:
|
> ### Here's an example code block
|
||||||
>
|
> ```
|
||||||
> return shell_exec("echo $input | $markdown_script");
|
> const PI = 3.1415`
|
||||||
|
> ```
|
||||||
|
|
||||||
Any decent text editor should make email-style quoting easy. For
|
Any decent text editor should make email-style quoting easy. For
|
||||||
example, with BBEdit, you can make a selection and choose Increase
|
example, with BBEdit, you can make a selection and choose Increase
|
||||||
Quote Level from the Text menu.
|
Quote Level from the Text menu.
|
||||||
|
|
||||||
|
|
||||||
### Lists
|
### Lists
|
||||||
|
|
||||||
Markdown supports ordered (numbered) and unordered (bulleted) lists.
|
Markdown supports ordered (numbered) and unordered (bulleted) lists.
|
||||||
|
|
@ -226,11 +220,14 @@ delimiters need to be indented:
|
||||||
> inside a list item.
|
> inside a list item.
|
||||||
|
|
||||||
To put a code block within a list item, the code block needs
|
To put a code block within a list item, the code block needs
|
||||||
to be indented *twice* — 8 spaces or two tabs:
|
to be indented with list item indentation in mind:
|
||||||
|
|
||||||
* A list item with a code block:
|
* A list item with a code block:
|
||||||
|
|
||||||
<code goes here>
|
```
|
||||||
|
code goes here
|
||||||
|
code goes here
|
||||||
|
```
|
||||||
|
|
||||||
### Code Blocks
|
### Code Blocks
|
||||||
|
|
||||||
|
|
@ -239,62 +236,65 @@ markup source code. Rather than forming normal paragraphs, the lines
|
||||||
of a code block are interpreted literally. Markdown wraps a code block
|
of a code block are interpreted literally. Markdown wraps a code block
|
||||||
in both `<pre>` and `<code>` tags.
|
in both `<pre>` and `<code>` tags.
|
||||||
|
|
||||||
To produce a code block in Markdown, simply indent every line of the
|
```
|
||||||
block by at least 4 spaces or 1 tab.
|
|
||||||
|
|
||||||
This is a normal paragraph:
|
|
||||||
|
|
||||||
This is a code block.
|
|
||||||
|
|
||||||
Here is an example of AppleScript:
|
|
||||||
|
|
||||||
tell application "Foo"
|
tell application "Foo"
|
||||||
beep
|
beep
|
||||||
end tell
|
end tell
|
||||||
|
```
|
||||||
A code block continues until it reaches a line that is not indented
|
|
||||||
(or the end of the article).
|
|
||||||
|
|
||||||
Within a code block, ampersands (`&`) and angle brackets (`<` and `>`)
|
|
||||||
are automatically converted into HTML entities. This makes it very
|
|
||||||
easy to include example HTML source code using Markdown — just paste
|
|
||||||
it and indent it, and Markdown will handle the hassle of encoding the
|
|
||||||
ampersands and angle brackets. For example, this:
|
|
||||||
|
|
||||||
<div class="footer">
|
|
||||||
© 2004 Foo Corporation
|
|
||||||
</div>
|
|
||||||
|
|
||||||
Regular Markdown syntax is not processed within code blocks. E.g.,
|
Regular Markdown syntax is not processed within code blocks. E.g.,
|
||||||
asterisks are just literal asterisks within a code block. This means
|
asterisks are just literal asterisks within a code block. This means
|
||||||
it's also easy to use Markdown to write about Markdown's own syntax.
|
it's also easy to use Markdown to write about Markdown's own syntax.
|
||||||
|
|
||||||
```
|
```
|
||||||
tell application "Foo"
|
## This is **not** a Markdown
|
||||||
beep
|
|
||||||
end tell
|
|
||||||
```
|
```
|
||||||
|
|
||||||
### Tables
|
### Tables
|
||||||
|
|
||||||
| Column 1 | Column 2 | Column 3 |
|
Markdown tables are created using pipes (|) to separate columns and hyphens (-) to define the header row. Here’s the basic structure:
|
||||||
| :------------- | :----------: | -----------: |
|
|
||||||
| Cell Contents | More Stuff | And Again |
|
1. Header Row: The first row contains column names.
|
||||||
| You Can Also | Put Pipes In | Like this [\|] |
|
2. Divider Line: The second row uses hyphens to separate the header from the data.
|
||||||
|
3. Data Rows: The rows below the divider contain the actual data.
|
||||||
|
|
||||||
|
| Name | Age | City |
|
||||||
|
|-------|-----|-------|
|
||||||
|
| Alice | 25 | New York |
|
||||||
|
| Bob | 30 | London |
|
||||||
|
|
||||||
|
You can style text inside Markdown table cells just like regular Markdown.
|
||||||
|
This includes making text bold, italic, monospaced, or adding links or code.
|
||||||
|
|
||||||
Column 1 | Column 2 | Column 3
|
Column 1 | Column 2 | Column 3
|
||||||
--- | --- | ---
|
--- | --- | ---
|
||||||
**Things** | _Don't_ | [Need](/)
|
**Things** | _Don't_ | [Need](/)
|
||||||
To | *__Look__* | `Pretty`
|
To | *__Look__* | `Pretty`
|
||||||
|
|
||||||
|
You can align text in Markdown table columns to the left, right, or center by placing a colon (:) in different positions within the header divider row.
|
||||||
|
|
||||||
|
1. Left-aligned: `:---` (Colon on the left)
|
||||||
|
2. Right-aligned: `---:` (Colon on the right)
|
||||||
|
3. Center-aligned: `:---:` (Colons on both sides)
|
||||||
|
|
||||||
|
| Column 1 | Column 2 | Column 3 |
|
||||||
|
| :------------- | :----------: | -----------: |
|
||||||
|
| Cell Contents | More Stuff | And Again |
|
||||||
|
| You Can Also | Put Pipes In | Like this [\|] |
|
||||||
|
|
||||||
|
Markdown tables don’t support merging cells (like in HTML).
|
||||||
|
Each cell is treated separately.
|
||||||
|
But if you want an empty space, just leave it blank.
|
||||||
|
|
||||||
|
| Header 1 | Header 2 |
|
||||||
|
|----------|----------|
|
||||||
|
| Cell 1 | |
|
||||||
|
| Cell 3 | Cell 4 |
|
||||||
|
|
||||||
## Span Elements
|
## Span Elements
|
||||||
|
|
||||||
### Links
|
### Links
|
||||||
|
|
||||||
Markdown supports two style of links: *inline* and *reference*.
|
|
||||||
|
|
||||||
In both styles, the link text is delimited by [square brackets].
|
|
||||||
|
|
||||||
To create an inline link, use a set of regular parentheses immediately
|
To create an inline link, use a set of regular parentheses immediately
|
||||||
after the link text's closing square bracket. Inside the parentheses,
|
after the link text's closing square bracket. Inside the parentheses,
|
||||||
put the URL where you want the link to point, along with an *optional*
|
put the URL where you want the link to point, along with an *optional*
|
||||||
|
|
@ -302,7 +302,7 @@ title for the link, surrounded in quotes. For example:
|
||||||
|
|
||||||
This is [an example](http://example.com/) inline link.
|
This is [an example](http://example.com/) inline link.
|
||||||
|
|
||||||
[This link](/example) has no title attribute.
|
[This link](/test/markdown/ "This is an example title") has a title attribute.
|
||||||
|
|
||||||
### Emphasis
|
### Emphasis
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue