Summary Files Commits Branches @commit @diff @stats
path: root / single.awk
diff options
context:
space:
mode:
1 files changed, 9 insertions, 32 deletions
-rw-r--r--single.awk41
diff --git a/single.awk b/single.awk
index 1e48ce7..7698bca 100644
--- a/single.awk
+++ b/single.awk
@@ -1,26 +1,10 @@
-# Status:
-# [.] Inline HTML
-# [x] Autoescape
-# [x] Block elements
-# [x] Paragraph
-# [x] Line break
-# [x] Headers (atx and setex)
-# [x] Blockquotes
-# [x] Lists
-# [x] Code blocks
-# [x] Horizontal rules
-# [x] Span elements
-# [x] Links
-# [x] Inline
-# [x] Reference
-# [x] Emphasis
-# [x] Code
-# [x] Images
-# [x] Inline
-# [x] Reference
-# [x] Other
-# [x] Autolinks
-# [x] Escapes
+# Almost the entire canonical Markdown specification is supported
+# https://daringfireball.net/projects/markdown/syntax
+# Notable behavioural exceptions are:
+# - Block-level HTML elements needn't be separated with blank lines
+# - Lists are identation-aware. List items begin and continue after the same
+# identation with which the list beginning (e.g. "* " or "5. ") was written.
+# The benefit is that all Markdown is parsed as normal inside an item.
#
# [ ] Non-standard features
# [ ] Strikethrough ~~...~~
@@ -36,15 +20,8 @@
# [ ] Links
# [ ] Link destination (<link> inside anchors)
# [ ] Nested links
-# No character classes, since they aren't supported on every system
#
-# Limitations:
-# - definition lists always contain one element, i.e. multiple definitions
-# aren't merged into the same list
-# - emphasis which isn't surrounded by blanks is still treated as emphasis
-# e.g. "some_text_here" will become "some<em>text</em>here"
-# - emphasis inside inline code block is still converted to HTML
-# - backticks inside `` emphasis blocks aren't escaped
+# No character classes have been used, since they aren't supported on every system
function empty(value) {
return value == ""
@@ -108,7 +85,7 @@ BEGIN {
}
# Output is buffered on multiple lines, held in these variables:
-# P2 = previous non-empty line
+# P2 = last non-empty line before the previous line
# P1 = previous line
# $0 = current line
# N1 = next new line (N1 is always set by the user)