aboutsummaryrefslogtreecommitdiff
path: root/src/Text/Pandoc
diff options
context:
space:
mode:
authorAlexander Krotov <ilabdsf@gmail.com>2017-11-13 18:41:30 +0300
committerAlexander Krotov <ilabdsf@gmail.com>2017-11-13 18:41:49 +0300
commit3a83b3843db6434e9806558ea1e912055d5baf04 (patch)
treeba8ae5cdcedf55e752f9325705f739ee3f48421d /src/Text/Pandoc
parente5e8350fcb3ea321efc28aaf88413677b3c97613 (diff)
downloadpandoc-3a83b3843db6434e9806558ea1e912055d5baf04.tar.gz
Replace "emacs" extension with "amuse" extension
It makes clear that extension is related to Muse markup.
Diffstat (limited to 'src/Text/Pandoc')
-rw-r--r--src/Text/Pandoc/Extensions.hs5
-rw-r--r--src/Text/Pandoc/Readers/Muse.hs2
2 files changed, 5 insertions, 2 deletions
diff --git a/src/Text/Pandoc/Extensions.hs b/src/Text/Pandoc/Extensions.hs
index ef05a597e..b7227860a 100644
--- a/src/Text/Pandoc/Extensions.hs
+++ b/src/Text/Pandoc/Extensions.hs
@@ -153,7 +153,7 @@ data Extension =
| Ext_smart -- ^ "Smart" quotes, apostrophes, ellipses, dashes
| Ext_old_dashes -- ^ -- = em, - before number = en
| Ext_spaced_reference_links -- ^ Allow space between two parts of ref link
- | Ext_emacs -- ^ Try to emulate Emacs Muse instead of Amusewiki
+ | Ext_amuse -- ^ Enable Text::Amuse extensions to Emacs Muse markup
deriving (Show, Read, Enum, Eq, Ord, Bounded, Data, Typeable, Generic)
instance ToJSON Extension where
@@ -315,6 +315,9 @@ getDefaultExtensions "markdown_phpextra" = phpMarkdownExtraExtensions
getDefaultExtensions "markdown_mmd" = multimarkdownExtensions
getDefaultExtensions "markdown_github" = githubMarkdownExtensions
getDefaultExtensions "markdown" = pandocExtensions
+getDefaultExtensions "muse" = extensionsFromList
+ [Ext_amuse,
+ Ext_auto_identifiers]
getDefaultExtensions "plain" = plainExtensions
getDefaultExtensions "gfm" = githubMarkdownExtensions
getDefaultExtensions "org" = extensionsFromList
diff --git a/src/Text/Pandoc/Readers/Muse.hs b/src/Text/Pandoc/Readers/Muse.hs
index 6739bc41f..13b517d09 100644
--- a/src/Text/Pandoc/Readers/Muse.hs
+++ b/src/Text/Pandoc/Readers/Muse.hs
@@ -423,7 +423,7 @@ definitionListItem = try $ do
pure $ do lineContent' <- lineContent
pure (B.text term, [lineContent'])
where
- termParser = (guardEnabled Ext_emacs <|> void spaceChar) >> -- Initial space is required by Amusewiki, but not Emacs Muse
+ termParser = (guardDisabled Ext_amuse <|> void spaceChar) >> -- Initial space is required by Amusewiki, but not Emacs Muse
many spaceChar >>
many1Till anyChar (lookAhead (void (try (spaceChar >> string "::")) <|> void newline))
endOfInput = try $ skipMany blankline >> skipSpaces >> eof