git.iko.soy/typeable/pandoc
on master help sign in
Removed "compatibility mode" when called as hsmarkdown.
commitc16efea9836a5e990deeac9f798627d39c289d35 authorJohn MacFarlane <jgm@berkeley.edu> dateSun 13 Dec 2015, 12:17 (11 years ago) parent678e7da
3 files changed+12−41
README−13 pandoc.cabal+10−16 pandoc.hs+2−12
README−13
@@ -227,19 +227,6 @@ or [variables for ConTeXt].
227227[`biber`]: https://ctan.org/pkg/biber
228228[TeX Live]: http://www.tug.org/texlive/
229229
230−`hsmarkdown`
231−------------
232−
233−A user who wants a drop-in replacement for `Markdown.pl` may create
234−a symbolic link to the `pandoc` executable called `hsmarkdown`. When
235−invoked under the name `hsmarkdown`, `pandoc` will behave as if
236−invoked with `-f markdown_strict --email-obfuscation=references`,
237−and all command-line options will be treated as regular arguments.
238−This approach does not work under [Cygwin], due to problems with
239−its simulation of symbolic links.
240−
241−[Cygwin]: https://cygwin.com
242−
243230Options
244231=======
245232
pandoc.cabal+10−16
@@ -15,28 +15,22 @@ Tested-With: GHC == 7.4.2, GHC == 7.6.3, GHC == 7.8.4, GHC == 7.10.2
1515Synopsis: Conversion between markup formats
1616Description: Pandoc is a Haskell library for converting from one markup
1717 format to another, and a command-line tool that uses
18− this library. It can read markdown and (subsets of) HTML,
19− reStructuredText, LaTeX, DocBook, MediaWiki markup, TWiki
20− markup, Haddock markup, OPML, Emacs Org-Mode, txt2tags,
21− Word Docx, ODT, and Textile, and it can write
22− Markdown, reStructuredText, XHTML, HTML 5, LaTeX,
23− ConTeXt, DocBook, OPML, OpenDocument, ODT,
18+ this library. It can read several dialects of Markdown and
19+ (subsets of) HTML, reStructuredText, LaTeX, DocBook,
20+ MediaWiki markup, TWiki markup, Haddock markup, OPML,
21+ Emacs Org-Mode, txt2tags, Word Docx, ODT, and Textile, and
22+ it can write Markdown, reStructuredText, XHTML, HTML 5,
23+ LaTeX, ConTeXt, DocBook, OPML, OpenDocument, ODT,
2424 Word docx, RTF, MediaWiki, DokuWiki, Textile, groff man
2525 pages, plain text, Emacs Org-Mode, AsciiDoc, Haddock markup,
2626 EPUB (v2 and v3), FictionBook2, InDesign ICML, and several
2727 kinds of HTML/javascript slide shows (S5, Slidy, Slideous,
2828 DZSlides, reveal.js).
2929 .
30− Pandoc extends standard markdown syntax with footnotes,
31− embedded LaTeX, definition lists, tables, and other
32− features. A compatibility mode is provided for those
33− who need a drop-in replacement for Markdown.pl.
34− .
35− In contrast to existing tools for converting markdown
36− to HTML, which use regex substitutions, pandoc has
37− a modular design: it consists of a set of readers,
38− which parse text in a given format and produce a native
39− representation of the document, and a set of writers,
30+ In contrast to most existing tools for converting Markdown
31+ to HTML, pandoc has a modular design: it consists of a set of
32+ readers, which parse text in a given format and produce a
33+ native representation of the document, and a set of writers,
4034 which convert this native representation into a target
4135 format. Thus, adding an input or output format requires
4236 only adding a reader or writer.
pandoc.hs+2−12
@@ -1047,25 +1047,15 @@ main = do
10471047
10481048 rawArgs <- map UTF8.decodeArg <$> getArgs
10491049 prg <- getProgName
1050− let compatMode = prg == "hsmarkdown"
10511050
1052− let (actions, args, errors) = if compatMode
1053− then ([], rawArgs, [])
1054− else getOpt Permute options rawArgs
1051+ let (actions, args, errors) = getOpt Permute options rawArgs
10551052
10561053 unless (null errors) $
10571054 err 2 $ concat $ errors ++
10581055 ["Try " ++ prg ++ " --help for more information."]
10591056
1060− let defaultOpts' = if compatMode
1061− then defaultOpts { optReader = "markdown_strict"
1062− , optWriter = "html"
1063− , optEmailObfuscation =
1064− ReferenceObfuscation }
1065− else defaultOpts
1066−
10671057 -- thread option data structure through all supplied option actions
1068− opts <- foldl (>>=) (return defaultOpts') actions
1058+ opts <- foldl (>>=) (return defaultOpts) actions
10691059
10701060 let Opt { optTabStop = tabStop
10711061 , optPreserveTabs = preserveTabs