Vim Pandoc

  1. Vim-pandoc Tutorial
  2. Vim Pandoc Tables
  3. Vim Pandoc Syntax
  4. Vim Pandoc Pdf
  5. Vim Pandoc Markdown
  6. Vim-pandoc Pdf
  7. Vim Pandoc

Pandoc is the swiss-army knife for converting files from one markup format into another. The Vim plugin for markdown is young and basic in comparison to. Vim bindings are provided via evil-mode, which can be configured separately and is installed by default in the Spacemacs distribution of Emacs (this is what I use, it comes with many nice defaults). Pandoc syntax highlighting - Markdown mode enables syntax highlighting for pandoc markup elements (there is also Pandoc mode, which I have not. For example: I have found the vim-pandoc-syntax plug-in particularly suitable for my highlighting needs. Nevertheless, I use the more general vim-markdown-folding for Markdown folding. By the way, only one flavour is allowed, separated by a dot, e.g.: filetype=markdown.pandoc. Gvim requires BufFilePre. When I run:%!pandoc -from=html -to=markdown pandoc -from=markdown -to=html, it works fine. I am trying to add the following command in my.vimrc after watching this vimcast.nnoremap. It is designed to work with vim-pandoc. To use it as a standalone plugin, we should add the following settings in our Neovim configuration file: augroup pandocsyntax au!

Original author(s)John MacFarlane
Initial release10 August 2006 (14 years ago)
Stable release
Written inHaskell
Operating systemUnix-like, Windows
PlatformIA-32, x64
LicenseGNU GPLv2

Pandoc is a free and open-sourcedocument converter, widely used as a writing tool (especially by scholars)[1] and as a basis for publishing workflows.[2] It was created by John MacFarlane, a philosophy professor at the University of California, Berkeley.[3]


Pandoc dubs itself a 'markup format' converter. It can take a document in one of the supported formats and convert only its markup to another format. Maintaining the look and feel of the document is not a priority.[4]

Plug-ins for custom formats can also be written in Lua, which has been used to create an exporting tool for the Journal Article Tag Suite, for example.[5]

An included CiteProc option allows Pandoc to use bibliographic data from reference management software in any of four formats: BibTeX, BibLaTeX, CSL JSON or CSL YAML.[6] The information is automatically transformed into a citation in various styles (such as APA, Chicago, or MLA) using an implementation of the Citation Style Language.[6] This allows the program to serve as a simpler alternative to LaTeX for producing academic writing.[7]

Supported file formats[edit]

Pandoc's most thoroughly supported file format is an extended version of Markdown,[8] but it can also read many other forms of:

  • FictionBook (FB2)
  • Jira wiki markup
  • Journal Article Tag Suite (JATS)
  • Markdown: Strict, CommonMark, GitHub Flavored Markdown (GFM), MultiMarkdown (MMD) and Markdown Extra (PHP Extra) variants
  • OpenDocument (ODT)
  • Office Open XML: Microsoft Word variant
  • txt2tags (t2t)
  • Wiki markup: MediaWiki, Muse, TikiWiki, TWiki and Vimwiki variants

It can create files in the following formats, which are not necessarily the same as the input formats:

  • DocBook: Versions 4 and 5
  • EPUB: Versions 2 and 3[9]
  • FictionBook (FB2)
  • HTML: HTML4 and HTML5 variants, respectively compliant with XHTML 1.0 Transitional and XHTML Strict
  • InDesign ICML
  • Jira wiki markup
  • Journal Article Tag Suite (JATS)
  • Markdown: Strict, CommonMark, GitHub Flavored Markdown (GFM), MultiMarkdown (MMD) and Markdown Extra (PHP Extra) variants
  • OpenDocument (ODT/ODF)
  • Office Open XML: Microsoft Word and Microsoft PowerPoint variants
  • PDF (needs a third-party add-on like ConTeXt, pdfroff, wkhtmltopdf, weasyprint or prince)[10]
  • Rich Text Format (RTF)
  • Web-based slideshows: LaTeX Beamer, Slideous, Slidy, DZSlides, reveal.js and S5 variants[11]
  • Wiki markup: DokuWiki, MediaWiki, Muse, TikiWiki, TWiki and Vimwiki variants

See also[edit]


  1. ^Mullen, Lincoln (23 February 2012). 'Pandoc Converts All Your (Text) Documents'. The Chronicle of Higher Education Blogs: ProfHacker. Retrieved 27 June 2014.
    - McDaniel, W. Caleb (28 September 2012). 'Why (and How) I Wrote My Academic Book in Plain Text'. W. Caleb McDaniel at Rice University. Retrieved 27 June 2014.
    - Healy, Kieran (23 January 2014). 'Plain Text, Papers, Pandoc'. Retrieved 27 June 2014.
    - Ovadia, Steven (2014). 'Markdown for Librarians and Academics'. Behavioral & Social Sciences Librarian. 33 (2): 120–124. doi:10.1080/01639269.2014.904696. ISSN0163-9269. S2CID62762368.
  2. ^Till, Kaitlyn; Simas, Shed; Larkai, Velma (14 April 2014). 'The Flying Narwhal: Small mag workflow'. Publishing @ SFU. Retrieved 11 March 2018.
    - Maxwell, John (1 November 2013). 'Building Publishing Workflows with Pandoc and Git'. Publishing @ SFU. Retrieved 27 June 2014.[permanent dead link]
    - Maxwell, John (26 February 2014). 'On Pandoc'. eBound Canada: Digital Production Workshop, Vancouver, BC. Archived from the original on 28 February 2015. Retrieved 27 June 2014.Cite journal requires journal= (help)
    - Maxwell, John (1 November 2013). 'Building Publishing Workflows with Pandoc and Git'. Publishing @ SFU. Retrieved 12 April 2019.
    - Krewinkel, Albert; Robert Winkler (8 May 2017). 'Formatting Open Science: agilely creating multiple document formats for academic manuscripts with Pandoc Scholar'. PeerJ Computer Science. 3: e112. doi:10.7717/peerj-cs.112. Retrieved 25 May 2017.
  3. ^'John MacFarlane'. Department of Philosophy. University of California, Berkeley. Retrieved 25 July 2014.
  4. ^'Pandoc User's Guide'. Description. Retrieved 22 January 2019. should not expect perfect conversions between every format and every other. Pandoc attempts to preserve the structural elements of a document, but not formatting details..
  5. ^Fenner, Martin (12 December 2013). 'From Markdown to JATS XML in one Step'. Gobbledygook. Retrieved 27 June 2014.
  6. ^ ab'Citations'. Pandoc User's Guide. Retrieved 2021-04-08.
  7. ^Tenen, Dennis; Grant Wythoff (19 March 2014). 'Sustainable Authorship in Plain Text using Pandoc and Markdown'. The Programming Historian. Retrieved 27 June 2014.
  8. ^'Pandoc's Markdown'. Pandoc User's Guide. Retrieved 2019-08-01.
  9. ^Mullen, Lincoln (20 March 2012). 'Make Your Own E-Books with Pandoc'. The Chronicle of Higher Education Blogs: ProfHacker. Retrieved 27 June 2014.
  10. ^'Getting started with pandoc'. Creating a PDF. Retrieved 22 January 2019.
  11. ^See as an example MacFarlane, John (17 May 2014). 'Pandoc for Haskell Hackers'. BayHac 2014, Mountain View, CA. Retrieved 27 June 2014.Cite journal requires journal= (help)CS1 maint: location (link) The source file is written in Markdown.

External links[edit]

Wikiversity has learning resources about PanDocElectron
Retrieved from ''

If you need to convert files from one markup format into another, pandoc is your swiss-army knife. Pandoc can convert between the following formats:

(← = conversion from; → = conversion to; ↔︎ = conversion from and to)


Lightweight markup formats

↔︎ Markdown (including CommonMark and GitHub-flavored Markdown)
↔︎ reStructuredText
→ AsciiDoc
↔︎ Emacs Org-Mode
↔︎ Emacs Muse
↔︎ Textile
← txt2tags

HTML formats

↔︎ (X)HTML 4
↔︎ HTML5


↔︎ EPUB version 2 or 3
↔︎ FictionBook2

Documentation formats

→ GNU TexInfo
↔︎ Haddock markup

Roff formats

↔︎ roff man
→ roff ms

TeX formats

↔︎ LaTeX
→ ConTeXt

XML formats

↔︎ DocBook version 4 or 5
→ TEI Simple

Outline formats


Bibliography formats

↔︎ BibTeX
↔︎ BibLaTeX

Word processor formats

↔︎ Microsoft Word docx
↔︎ OpenOffice/LibreOffice ODT
→ OpenDocument XML
→ Microsoft PowerPoint

Interactive notebook formats

↔︎ Jupyter notebook (ipynb)

Page layout formats

→ InDesign ICML

Vim-pandoc Tutorial

Wiki markup formats

↔︎ MediaWiki markup
↔︎ DokuWiki markup
← TikiWiki markup
← TWiki markup
← Vimwiki markup
→ XWiki markup
→ ZimWiki markup
↔︎ Jira wiki markup

Slide show formats
Vim Pandoc

→ LaTeX Beamer
→ Slidy
→ reveal.js
→ Slideous
→ S5
→ DZSlides

Data formats

← CSV tables

Vim Pandoc Tables

Custom formats

→ custom writers can be written in lua.

Vim Pandoc Syntax


→ via pdflatex, lualatex, xelatex, latexmk, tectonic, wkhtmltopdf, weasyprint, prince, context, or pdfroff.

Pandoc understands a number of useful markdown syntax extensions, including document metadata (title, author, date); footnotes; tables; definition lists; superscript and subscript; strikeout; enhanced ordered lists (start number and numbering style are significant); running example lists; delimited code blocks with syntax highlighting; smart quotes, dashes, and ellipses; markdown inside HTML blocks; and inline LaTeX. If strict markdown compatibility is desired, all of these extensions can be turned off.

LaTeX math (and even macros) can be used in markdown documents. Several different methods of rendering math in HTML are provided, including MathJax and translation to MathML. LaTeX math is converted (as needed by the output format) to unicode, native Word equation objects, MathML, or roff eqn.

Vim Pandoc Pdf

Pandoc includes a powerful system for automatic citations and bibliographies. This means that you can write a citation like

Vim pandoc folding

and pandoc will convert it into a properly formatted citation using any of hundreds of CSL styles (including footnote styles, numerical styles, and author-date styles), and add a properly formatted bibliography at the end of the document. The bibliographic data may be in BibTeX, BibLaTeX, CSL JSON, or CSL YAML format. Citations work in every output format.

Vim Pandoc Markdown

There are many ways to customize pandoc to fit your needs, including a template system and a powerful system for writing filters.

Vim-pandoc Pdf

Pandoc includes a Haskell library and a standalone command-line program. The library includes separate modules for each input and output format, so adding a new input or output format just requires adding a new module.

Vim Pandoc

Pandoc is free software, released under the GPL. Copyright 2006–2020 John MacFarlane.