The Wiert Corner – irregular stream of stuff

Jeroen W. Pluimers on .NET, C#, Delphi, databases, and personal interests

  • My badges

  • Twitter Updates

  • My Flickr Stream

  • Pages

  • All categories

  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 1,437 other followers

pandoc oneliner from reStructuredText to html

Posted by jpluimers on 2016/05/12

[WayBack] Pandoc is so versatile that you sometimes forget a conversion can be as simple as a one-liner:

pandoc -s README.rst -o readme.html

This converts the reStructured text in README.rst to html.

Pandoc is smart enough to recognise the conversions without you telling the formats with -f (input format) and -t (output format) explicitly.

If you do need to explicitly specify the format, it is useful to query which formats are supported as per [WayBack] Pandoc – Pandoc User’s Guide: specifying formats:

  • pandoc --list-input-formats
  • pandoc --list-output-formats

On my system, these are supported:

pandoc --list-input-formats

commonmark
creole
docbook
docx
epub
fb2
gfm
haddock
html
jats
json
latex
markdown
markdown_github
markdown_mmd
markdown_phpextra
markdown_strict
mediawiki
muse
native
odt
opml
org
rst
t2t
textile
tikiwiki
twiki
vimwikia

pandoc --list-output-formats

asciidoc
beamer
commonmark
context
docbook
docbook4
docbook5
docx
dokuwiki
dzslides
epub
epub2
epub3
fb2
gfm
haddock
html
html4
html5
icml
jats
json
latex
man
markdown
markdown_github
markdown_mmd
markdown_phpextra
markdown_strict
mediawiki
ms
muse
native
odt
opendocument
opml
org
plain
pptx
revealjs
rst
rtf
s5
slideous
slidy
tei
texinfo
textile
zimwiki

–jeroen

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

 
%d bloggers like this: