Also copy exercises
All checks were successful
the build was successful

This commit is contained in:
Valentin Brandl 2018-10-15 20:12:05 +02:00
parent 634613a2d4
commit 4f8b9c95aa
No known key found for this signature in database
GPG Key ID: 30D341DD34118D7D

View File

@ -1,5 +1,8 @@
.PHONY: default clean .PHONY: default clean
COPY_PDF=$(shell find . -name '*.pdf' -not -path './build/*')
COPY_TARGETS=$(COPY_PDF:%.pdf=build/%.pdf)
MD_SOURCES=$(shell find . -name '*.md' -not -path "./templates/*") MD_SOURCES=$(shell find . -name '*.md' -not -path "./templates/*")
HTML_TARGETS=$(MD_SOURCES:%.md=build/%.html) HTML_TARGETS=$(MD_SOURCES:%.md=build/%.html)
PDF_TARGETS=$(MD_SOURCES:%.md=build/%.pdf) PDF_TARGETS=$(MD_SOURCES:%.md=build/%.pdf)
@ -14,7 +17,7 @@ COMPRESS_TARGETS=$(HTML_TARGETS:%=%.gz)
COMPRESS_TARGETS+=$(PDF_TARGETS:%=%.gz) COMPRESS_TARGETS+=$(PDF_TARGETS:%=%.gz)
COMPRESS_TARGETS+=$(TEX_TARGETS:%=%.gz) COMPRESS_TARGETS+=$(TEX_TARGETS:%=%.gz)
default: $(DOT_TARGETS) $(HTML_TARGETS) $(PDF_TARGETS) $(TEX_TARGETS) default: $(DOT_TARGETS) $(HTML_TARGETS) $(PDF_TARGETS) $(TEX_TARGETS) $(COPY_TARGETS)
compress: default $(COMPRESS_TARGETS) compress: default $(COMPRESS_TARGETS)
@ -37,5 +40,9 @@ build/%.pdf: %.tex
%.gz: % %.gz: %
gzip -k -f -9 $< gzip -k -f -9 $<
build/%.pdf: %.pdf
@mkdir -p $$(dirname $@)
cp $< $@
clean: clean:
rm -r build rm -r build