aboutsummaryrefslogtreecommitdiff
path: root/src/Text
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2020-07-29 18:13:15 -0700
committerJohn MacFarlane <jgm@berkeley.edu>2020-07-29 18:13:15 -0700
commit2077739a35fd51ca6f482ce8a108d10799f5b274 (patch)
treeb01e58c59c752f920509ffabd2ae0ef1682b1a9c /src/Text
parentaff582d9b5bcd0653bfb11f13c1fec7c16a34aa7 (diff)
downloadpandoc-2077739a35fd51ca6f482ce8a108d10799f5b274.tar.gz
Add extensions to `gfm` and `commonmark`:
`fenced_code_blocks`, `backtick_code_blocks`, `fenced_code_attributes`. These can't really be disabled in the reader, but they need to be enabled in the writer or we just get indented code.
Diffstat (limited to 'src/Text')
-rw-r--r--src/Text/Pandoc/Extensions.hs8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/Text/Pandoc/Extensions.hs b/src/Text/Pandoc/Extensions.hs
index c0a906d1b..430d13401 100644
--- a/src/Text/Pandoc/Extensions.hs
+++ b/src/Text/Pandoc/Extensions.hs
@@ -253,6 +253,8 @@ githubMarkdownExtensions = extensionsFromList
, Ext_strikeout
, Ext_task_lists
, Ext_emoji
+ , Ext_fenced_code_blocks
+ , Ext_backtick_code_blocks
]
-- | Extensions to be used with multimarkdown.
@@ -362,6 +364,9 @@ getDefaultExtensions "commonmark_x" = extensionsFromList
, Ext_raw_attribute
, Ext_implicit_header_references
, Ext_attributes
+ , Ext_fenced_code_blocks
+ , Ext_fenced_code_attributes
+ , Ext_backtick_code_blocks
]
getDefaultExtensions "org" = extensionsFromList
[Ext_citations,
@@ -484,6 +489,9 @@ getAllExtensions f = universalExtensions <> getAll f
, Ext_raw_attribute
, Ext_implicit_header_references
, Ext_attributes
+ , Ext_fenced_code_blocks
+ , Ext_fenced_code_attributes
+ , Ext_backtick_code_blocks
]
getAll "commonmark_x" = getAll "commonmark"
getAll "org" = autoIdExtensions <>