Added a makefile

This commit is contained in:
rconnorjohnstone
2021-04-03 19:01:19 -06:00
parent f8cb8f77a5
commit 97a5648ca2
3 changed files with 34 additions and 0 deletions

21
Makefile Normal file
View File

@@ -0,0 +1,21 @@
OPTIONS = markdown+yaml_metadata_block+smart
NOTES_DIR = prelim_notes
PDF_DIR = pdf
NOTES = $(wildcard $(NOTES_DIR)/*.md)
PDFS = $(patsubst %.md,%.pdf,$(subst $(NOTES_DIR),$(PDF_DIR),$(NOTES)))
all: $(PDFS)
$(PDF_DIR)/%.pdf: $(NOTES_DIR)/%.md pdf_dir
pandoc \
--variable mainfont="Roboto" \
--variable monofont="Fira Code" \
--variable fontsize=11pt \
--variable geometry:"top=1in, bottom=1in, left=1in, right=1in" \
--variable geometry:letterpaper \
-f markdown $< \
-o $@
pdf_dir:
mkdir -p $(PDF_DIR)