Pandoc is a universal document converter.
Based on the provided sources, Pandoc is a universal document converter, acting as a "swiss-army knife" for converting files between various markup formats.
Features:
Format Conversion: Pandoc can convert between a wide array of formats, including:
Lightweight markup formats like Markdown, reStructuredText, AsciiDoc, Emacs Org-Mode, and others.
HTML formats such as (X)HTML 4 and HTML5.
Ebook formats including EPUB and FictionBook2.
Documentation formats like GNU TexInfo and Haddock markup.
TeX formats such as LaTeX and ConTeXt.
XML formats like DocBook and JATS.
Outline formats like OPML.
Bibliography formats including BibTeX, BibLaTeX, and CSL JSON.
Word processor formats such as Microsoft Word docx, RTF, and ODT.
Interactive notebook formats like Jupyter notebook (ipynb).
Page layout formats such as InDesign ICML and Typst.
Wiki markup formats like MediaWiki, DokuWiki, and others.
Slide show formats like LaTeX Beamer, Microsoft PowerPoint, and reveal.js.
Data formats like CSV and TSV tables (as input).
Terminal output in ANSI-formatted text.
Custom formats through user-written Lua readers and writers.
PDF generation via various TeX engines and other tools.
Markdown Extensions: Pandoc understands and can utilize several useful Markdown syntax extensions, including:
Document metadata (title, author, date)
Footnotes
Tables
Definition lists
Superscript and subscript
Strikeout
Enhanced ordered lists
Running example lists
Delimited code blocks with syntax highlighting
Smart quotes, dashes, and ellipses
Markdown inside HTML blocks
Inline LaTeX
These extensions can be turned off for strict Markdown compatibility.
LaTeX Math Support: Pandoc can handle LaTeX math (and even macros) within Markdown documents. It offers different methods for rendering math in HTML, such as MathJax and MathML conversion, and can convert LaTeX math to Unicode, native Word equation objects, MathML, or roff eqn as needed by the output format.
Automatic Citations and Bibliographies: Pandoc features a powerful system for automatic citations and bibliographies. Users can write citations using a specific syntax (e.g., [@doe99]
) and Pandoc will automatically format them according to hundreds of CSL styles and generate a bibliography at the end of the document. It supports bibliographic data in BibTeX, BibLaTeX, CSL JSON, and CSL YAML formats, and citations work across all output formats.
Customization: Pandoc offers various ways to be customized, including a template system and a powerful system for writing filters.
Architecture: Pandoc includes a Haskell library and a standalone command-line program. Its library has separate modules for each input and output format, making it easier to add new format support.
Licensing: Pandoc is free software released under the GPL.
In summary, Pandoc's primary functionality is its ability to seamlessly convert between a vast number of different document formats, making it an incredibly versatile tool for anyone working with text-based files. It also enhances Markdown with useful extensions and provides robust support for LaTeX math and automatic bibliography generation. The tool is designed to be customizable and extensible.