tldr/pages/common/pandoc.md

24 lines
561 B
Markdown
Raw Normal View History

2015-11-09 12:52:05 +00:00
# pandoc
> Convert documents between various formats.
2015-11-09 12:52:05 +00:00
2018-10-24 23:46:08 +01:00
- Convert file to pdf (the output format is determined by file extension):
2015-11-09 12:52:05 +00:00
2015-11-25 07:51:55 +00:00
`pandoc {{input.md}} -o {{output.pdf}}`
2018-10-24 23:46:08 +01:00
- Force conversion to use a specific format:
`pandoc {{input.docx}} --to {{markdown_github}} -o {{output.md}}`
2018-10-24 23:46:08 +01:00
- Convert to a standalone file with the appropriate headers/footers (for LaTeX, HTML, etc.):
`pandoc {{input.md}} -s -o {{output.tex}}`
- List all supported input formats:
`pandoc --list-input-formats`
- List all supported output formats:
`pandoc --list-output-formats`