File: markdown.md

package info (click to toggle)
tcllib 1.20%2Bdfsg-1
  • links: PTS
  • area: main
  • in suites: bullseye
  • size: 68,064 kB
  • sloc: tcl: 216,842; ansic: 14,250; sh: 2,846; xml: 1,766; yacc: 1,145; pascal: 881; makefile: 107; perl: 84; f90: 84; python: 33; ruby: 13; php: 11
file content (93 lines) | stat: -rw-r--r-- 2,846 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
# Markdown

*Markdown* is a Markdown to XHTML processor.  It supports the original 
basic syntax as defined by John Gruber on his homepage at [http://daringfireball.net/projects/markdown/syntax](http://daringfireball.net/projects/markdown/syntax).

# Markdown Dialect

Tcl-markdown is intended to support the same range of inputs and outputs
as John Gruber's original Markdown processor.

Common extensions are not supported at this time.

## Known Bugs

Per Markdown.mdtest, reflink text can contain brackets.   This input
should produce a link to the "/url/"; at present it does not
(see Tcl-markdown test mdtest-1.3):
```
With [embedded [brackets]] [b].

[b]: /url/
```

Simple reference links are ignored.  The following link should be
expanded, but it isn't (see Tcl-markdown test mdtest-1.4):

```
Simple link [this].

[this]: /url/
```

Oddly, a line beginning and ending with brackets can contain 
reference links within it.  The following links should be expanded,
but are not (see Tcl-markdown tests mdtest-1.5 and 1.6):

```
[Links can be [embedded][] in brackets]
[Links can be [embedded] in brackets]

[embedded]: /url/

```

Simple reflinks can have line breaks in them; these are currently not
supported (see Tcl-markdown tests mdtest-1.7 and 1.8):

```
The [link
breaks] across lines.

The [link 
breaks] across lines, but with a line-ending space.

[link breaks]: /url/

```

## Mdtest Results

Tcl-markdown has been run against the Markdown.mdtest test set provided by 
[mdtest](https://github.com/michelf/mdtest) test suite, with mixed 
results.  

* Running the test suite on OSX 10.8.5, using PHP 5.3.28, most
  tests fail.  Examination of the results reveals that most of the 
  "failures" involve whitespace differences with no effect on the rendered
  appearance of the output.

* Running the test suite on OSX 10.9, using PHP 5.4.30, most tests pass.
  The test files and Tcl-markdown outputs are identical on both platforms.
  My conjecture is that an XML-parser is used to compare the actual and
  expected results, and that the comparison is a little more forgiving on 
  PHP 5.4.30.

I am trying to fix substantive bugs; but see the mdtest-\*.\* tests
in test/markdown/markdown.test that are tagged with the constraint
"knownbug".

## CommonMark Results

Tcl-markdown has not been run against the CommonMark test suite as yet.
I would like to evolve it into a CommonMark compliant processor, but that
will take some time.

# Provenance

This module originated as the Tcl-Markdown project by Tobias Koch and Danyil Bohdan, 
as part of the Caius Test Tool. [https://github.com/tobijk/caius/](https://github.com/tobijk/caius/)

That module incorporated into Tcllib is based on a version that modifed and enhanced 
by Will Duquette. [https://github.com/wduquette/tcl-markdown](https://github.com/wduquette/tcl-markdown)