-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
19 lines (15 loc) · 835 Bytes
/
Makefile
File metadata and controls
19 lines (15 loc) · 835 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
default all: pdf
TMPDIR:=$(shell mktemp -d /tmp/latex.XXXX)
%: %.tex
@test -d $(TMPDIR) || mkdir $(TMPDIR)
@echo "Running 2 compiles - $(TMPDIR)"
@pdflatex -output-directory=$(TMPDIR) -interaction=batchmode -file-line-error -no-shell-escape $< > /dev/null
@pdflatex -output-directory=$(TMPDIR) -interaction=batchmode -file-line-error -no-shell-escape $< > /dev/null
@cp $(TMPDIR)/$@.pdf .
@echo "VanTosh $@ Ready"
.PHONY: gitinfo
gitinfo:
@git log -1 --date=short --pretty=format:"\usepackage[shash={%h},lhash={%H},authname={%an},authemail={%ae},authsdate={%ad},authidate={%ai},authudate={%at},commname={%an},commemail={%ae},commsdate={%ad},commidate={%ai},commudate={%at},refnames={%d},firsttagdescribe="${FIRSTTAG}",reltag="${RELTAG}"]{gitexinfo}" HEAD > $(TMPDIR)/gitHeadLocal.gin
.PHONY: clean
clean:
@rm -rf $(TMPDIR)