pandoc-templates/handin/makefile

19 lines
336 B
Makefile
Raw Normal View History

2016-11-10 14:13:26 +00:00
TEX = pandoc
2016-11-23 21:48:44 +00:00
texsrc = template.tex handin.md
2017-10-24 12:46:06 +00:00
src = out.pdf
FLAGS = --latex-engine=pdflatex
pdfname = $(shell basename $(CURDIR)).pdf
2016-11-10 14:13:26 +00:00
2016-11-23 21:48:44 +00:00
package: $(src)
2017-10-24 12:46:06 +00:00
mkdir -p out
cp $(src) out/
mv out/out.pdf out/$(pdfname)
2016-11-23 21:48:44 +00:00
2017-10-24 12:46:06 +00:00
out.pdf : $(texsrc)
2016-11-10 14:13:26 +00:00
$(TEX) $(filter-out $<,$^ ) -o $@ --template=$< $(FLAGS)
.PHONY: clean
clean :
2017-10-24 12:46:06 +00:00
rm out.pdf
rm -R out