Invoke pandoc from any text editor with the opened file as input.
This is achieved using Mac OS X services.
- Copy the files to your
~/Library/Services
folder - Restart your editor, open and save a file containing some markdown
- Go to the
Services
menu (for example if you're using Sublime:Sublime > Services
) and choose a service likePandoc PDF
. - After a few seconds, the PDF file will appear in the same folder as your markdown file
- Finally, you can assign a keyboard shortcut to invoke a service in
System Preferences > Keyboard > Keyboard Shortcuts > Services (on the left)
.
Pandoc PDF with Template
and Pandoc ConTeXt PDF with Template
look for a template.tex
or contextTemplate.tex
file respectively in the same directory as the input file.
To get a copy of the default pandoc template to customize, use pandoc -D latex > template.tex
or pandoc -D context > contextTemplate.tex
respectively.