To see the output created by each of the commands below, click on the name of the output file:
HTML fragment:
pandoc README -o example1.html
(View example1.html as a web page.)
Standalone HTML file:
pandoc -s README -o example2.html
(View example2.html as a web page.)
HTML with smart quotes, table of contents, CSS, and custom footer:
pandoc -s -S --toc -c pandoc.css -A footer.html README -o example3.html
(View example3.html as a web page.)
LaTeX:
pandoc -s README -o example4.tex
From LaTeX to markdown:
pandoc -s example4.tex -o example5.text
reStructuredText:
pandoc -s -w rst --toc README -o example6.text
Rich text format (RTF):
pandoc -s README -o example7.rtf
S5 HTML slide show (all in one file):
pandoc -s -m -i -w s5 S5DEMO -o example8.html
(View example8.html as a web page.)
DocBook XML:
pandoc -s -S -w docbook README -o example9.db
Chunked XHTML via DocBook and xmlto:
xmlto xhtml -m config.xsl example9.db -o example9/
Man page:
pandoc -s -w man pandoc.1.md -o example10.1
ConTeXt:
pandoc -s -w context README -o example11.tex
PDF via pandoc and ConTeXt's texexec:
texexec --pdf example11.tex # produces example11.pdf
Converting a web page to markdown:
pandoc -s -r html http://www.gnu.org/software/make/ -o example12.text
From markdown to PDF:
markdown2pdf README -o example13.pdf
PDF with numbered sections and a custom LaTeX header:
markdown2pdf -N --template=mytemplate.tex --variable version=1.4 README --xetex --toc -o example14.pdf
A web application that uses pandoc to convert web pages to any of eight different formats: html2x.
TeX math in HTML:
pandoc math.text -s -o mathDefault.html
pandoc math.text -s --mathml -o mathMathML.html
pandoc math.text -s -m -o mathLaTeXMathML.html
pandoc math.text -s --mimetex=/cgi-bin/mimetex.cgi -o mathMimetex.html
pandoc math.text -s --gladtex -o mathGladtex.htex
gladtex mathGladtex.htex # produces mathGladtex.html
Syntax highlighting of delimited code blocks:
pandoc code.text -s -o example18.html
(View example18.html as a web page.)
GNU Texinfo, converted to info, HTML, and PDF formats:
pandoc README -s -o example19.texi
makeinfo example19.texi -o example19.info
makeinfo example19.texi --html -o example19
texi2pdf example19.texi # produces example19.pdf
OpenDocument XML:
pandoc README -s -w opendocument -o example20.xml
ODT (OpenDocument Text, readable by OpenOffice):
pandoc README -o example21.odt
MediaWiki markup:
pandoc -s -S -w mediawiki --toc README -o example22.wiki