Skip to content

Instantly share code, notes, and snippets.

@svenax
Created December 8, 2012 16:26
Show Gist options
  • Save svenax/4240892 to your computer and use it in GitHub Desktop.
Save svenax/4240892 to your computer and use it in GitHub Desktop.
Pandoc make file
SOURCE = example_file.md
HTML = $(SOURCE:.md=.html)
PDF = $(SOURCE:.md=.pdf)
WIKI = $(SOURCE:.md=.wiki)
all: $(HTML) $(PDF) $(WIKI)
clean:
rm -f *.aux *.tex *.out *.log *.html *.pdf *.wiki
$(HTML): $(SOURCE)
pandoc -NSs $(SOURCE) -o $(HTML)
$(PDF): $(SOURCE)
pandoc -NSs --variable=fontsize:11pt \
--variable=geometry:a4paper,margin=2cm \
$(SOURCE) -o $(PDF)
$(WIKI): $(SOURCE)
pandoc -S $(SOURCE) -t mediawiki -o $(WIKI)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment