Removed --enable, --disable options.
This commit is contained in:
parent
a740de0508
commit
41e0075789
2 changed files with 4 additions and 40 deletions
14
README
14
README
|
@ -163,14 +163,6 @@ General options
|
|||
will be rendered as literate Haskell source: see [Literate Haskell
|
||||
support](#literate-haskell-support), below.
|
||||
|
||||
`-e` *EXTENSION*, `--enable=`*EXTENSION*
|
||||
: Enable the specified markdown syntax extension. For a list of extensions,
|
||||
see [Pandoc's markdown](#pandocs-markdown), below.
|
||||
|
||||
`-d` *EXTENSION*, `--disable=`*EXTENSION*
|
||||
: Disable the specified markdown syntax extension. For a list of extensions,
|
||||
see [Pandoc's markdown](#pandocs-markdown), below.
|
||||
|
||||
`-o` *FILE*, `--output=`*FILE*
|
||||
: Write output to *FILE* instead of *stdout*. If *FILE* is
|
||||
`-`, output will go to *stdout*. (Exception: if the output
|
||||
|
@ -773,9 +765,7 @@ Pandoc understands an extended and slightly revised version of
|
|||
John Gruber's [markdown] syntax. This document explains the syntax,
|
||||
noting differences from standard markdown. Except where noted, these
|
||||
differences can be suppressed by specifying the `--strict` command-line
|
||||
option. They can also be disabled piecemeal using the `--disable`
|
||||
(or `-d`) option. If `--strict` is used, `--enable` (or `-e`) can be
|
||||
used to turn on specific extensions.
|
||||
option.
|
||||
|
||||
Philosophy
|
||||
----------
|
||||
|
@ -2175,7 +2165,7 @@ Non-pandoc extensions
|
|||
=====================
|
||||
|
||||
The following markdown syntax extensions are not enabled by default
|
||||
in pandoc, but can be enabled using the `-e` (`--enable`) option:
|
||||
in pandoc.
|
||||
|
||||
**Extension: `hard_line_breaks`**\
|
||||
Causes all newlines within a paragraph to be interpreted as hard line
|
||||
|
|
|
@ -134,7 +134,6 @@ data Opt = Opt
|
|||
, optDumpArgs :: Bool -- ^ Output command-line arguments
|
||||
, optIgnoreArgs :: Bool -- ^ Ignore command-line arguments
|
||||
, optStrict :: Bool -- ^ Use strict markdown syntax
|
||||
, optExtensions :: [(Bool, Extension)]-- ^ Extensions to enable/disable
|
||||
, optReferenceLinks :: Bool -- ^ Use reference links in writing markdown, rst
|
||||
, optWrapText :: Bool -- ^ Wrap text
|
||||
, optColumns :: Int -- ^ Line length in characters
|
||||
|
@ -188,7 +187,6 @@ defaultOpts = Opt
|
|||
, optDumpArgs = False
|
||||
, optIgnoreArgs = False
|
||||
, optStrict = False
|
||||
, optExtensions = []
|
||||
, optReferenceLinks = False
|
||||
, optWrapText = True
|
||||
, optColumns = 72
|
||||
|
@ -242,24 +240,6 @@ options =
|
|||
(\opt -> return opt { optStrict = True } ))
|
||||
"" -- "Disable markdown syntax extensions"
|
||||
|
||||
, Option "e" ["enable"]
|
||||
(ReqArg
|
||||
(\arg opt -> do
|
||||
ext <- readExtension arg
|
||||
return opt { optExtensions =
|
||||
(True,ext) : optExtensions opt } )
|
||||
"EXTENSION")
|
||||
"" -- "Enable specific markdown syntax extensions"
|
||||
|
||||
, Option "d" ["disable"]
|
||||
(ReqArg
|
||||
(\arg opt -> do
|
||||
ext <- readExtension arg
|
||||
return opt { optExtensions =
|
||||
(False,ext) : optExtensions opt } )
|
||||
"EXTENSION")
|
||||
"" -- "Disable specific markdown syntax extensions"
|
||||
|
||||
, Option "R" ["parse-raw"]
|
||||
(NoArg
|
||||
(\opt -> return opt { optParseRaw = True }))
|
||||
|
@ -840,7 +820,6 @@ main = do
|
|||
, optDumpArgs = dumpArgs
|
||||
, optIgnoreArgs = ignoreArgs
|
||||
, optStrict = strict
|
||||
, optExtensions = exts
|
||||
, optReferenceLinks = referenceLinks
|
||||
, optWrapText = wrap
|
||||
, optColumns = columns
|
||||
|
@ -967,12 +946,7 @@ main = do
|
|||
then strictExtensions
|
||||
else pandocExtensions
|
||||
|
||||
let extensions = foldl (\acc (inc,ext) -> if inc
|
||||
then Set.insert ext acc
|
||||
else Set.delete ext acc)
|
||||
defaultExts exts
|
||||
|
||||
let readerOpts = def{ readerExtensions = extensions
|
||||
let readerOpts = def{ readerExtensions = defaultExts
|
||||
, readerSmart = smart || (texLigatures &&
|
||||
(laTeXOutput || writerName' == "context"))
|
||||
, readerStandalone = standalone'
|
||||
|
@ -998,7 +972,7 @@ main = do
|
|||
writerIgnoreNotes = False,
|
||||
writerNumberSections = numberSections,
|
||||
writerSectionDivs = sectionDivs,
|
||||
writerExtensions = extensions,
|
||||
writerExtensions = defaultExts,
|
||||
writerReferenceLinks = referenceLinks,
|
||||
writerWrapText = wrap,
|
||||
writerColumns = columns,
|
||||
|
|
Loading…
Add table
Reference in a new issue