efrei/communications-numeriques/tp/Makefile

17 lines
367 B
Makefile
Raw Normal View History

2022-05-02 12:45:23 +02:00
filename=$(shell basename $(shell pwd))
2022-04-26 10:36:36 +02:00
timestamp=$(shell date +%Y-%m-%d_%H:%M)
2022-05-02 12:45:23 +02:00
all: snapshot
2022-04-26 10:36:36 +02:00
2022-05-02 12:45:23 +02:00
snapshot: main.tex
@latexmk -pdf main.tex
@if ! cmp --silent build/main.pdf ${filename}_*.pdf; then \
touch ${filename}_tmp.pdf; \
rm ${filename}*.pdf; \
cp build/main.pdf ${filename}_${timestamp}.pdf; \
2022-04-26 10:36:36 +02:00
echo "Updated"; \
fi
clean:
@rm -rf build 2>/dev/null