Skip to content

Instantly share code, notes, and snippets.

View anthonysterling's full-sized avatar
:octocat:
Working on GitHub Actions

Anthony Sterling anthonysterling

:octocat:
Working on GitHub Actions
View GitHub Profile
@anthonysterling
anthonysterling / osx-pdf-from-markdown.markdown
Created July 9, 2018 10:56 — forked from georgiana-gligor/osx-pdf-from-markdown.markdown
Markdown source for the "Create PDF files from Markdown sources in OSX" article

Create PDF files from Markdown sources in OSX

When [Markdown][markdown] appeared more than 10 years ago, it aimed to make it easier to express ideas in an easy-to-write plain text format. It offers a simple syntax that takes the writer focus away from the formatting, thus giving her time to focus on the actual content.

The market abunds of editors to be used for help with markdown. After a few attempts, I settled to Sublime and its browser preview plugin, which work great for me and have a small memory footprint to accomplish that. To pass the results around to other people, less technical, a markdown file and a bunch of images is not the best approach, so converting it to a more robust format like PDF seems like a much better choice.

[Pandoc][pandoc] is the swiss-army knife of converting documents between various formats. While being able to deal with heavy-weight formats like docx and epub, we will need it for the more lightweight markdown. To be able to generate PDF files, we need LaTeX. On OSX, the s