revert Makefile

This commit is contained in:
Jan Grewe 2024-05-03 15:59:17 +02:00
parent 7a9bbd1fbd
commit 006fb712bf

View File

@ -1,31 +1,24 @@
TEXBASE=highbeats TEXBASE=susceptibility1
BIBFILE=references.bib BIBFILE=references.bib
REBUTTALBASE=rebuttal3 REBUTTALBASE=
TEXFILE=$(TEXBASE).tex TEXFILE=$(TEXBASE).tex
PDFFILE=$(TEXBASE).pdf PDFFILE=$(TEXBASE).pdf
TXTFILE=$(TEXBASE).txt TXTFILE=$(TEXBASE).txt
REVISION=cb626892bd10b2908691bd95767f87c3d6a57dfe REVISION=
ALLPDFFIGURES=$(shell sed -n -e '/^[^%].*includegraphics/{s/^.*includegraphics.*{\([^}]*\)}.*/\1.pdf/;p}' $(TEXFILE))
PDFFIGURES=$(filter-out toblerone_animated.pdf, $(ALLPDFFIGURES))
PT=$(wildcard *.py)
PYTHONFILES=$(filter-out plotstyle.py myfunctions.py numerical_compar_both.py, $(PT))
PYTHONPDFFILES=$(PYTHONFILES:.py=.pdf)
ifdef REBUTTALBASE ifdef REBUTTALBASE
REBUTTALTEXFILE=$(REBUTTALBASE).tex REBUTTALTEXFILE=$(REBUTTALBASE).tex
REBUTTALPDFFILE=$(REBUTTALBASE).pdf REBUTTALPDFFILE=$(REBUTTALBASE).pdf
endif endif
REBUTTALREVISION=68900a1 REBUTTALREVISION=
# all ########################################################### # all ###########################################################
ifdef REBUTTALBASE ifdef REBUTTALBASE
all: bib supplement rebuttalbib all: bib rebuttalbib
else else
all: bib supplement all: bib
endif endif
# python ######################################################### # python #########################################################
@ -37,9 +30,9 @@ watchplots :
while true; do ! make -q plots && make plots; sleep 0.5; done while true; do ! make -q plots && make plots; sleep 0.5; done
# manuscript ##################################################### # rescue_local_eod manuscript #################################################
bib: $(TEXBASE).bbl bib: $(TEXBASE).bbl
$(TEXBASE).bbl: $(TEXFILE) $(BIBFILE) $(PDFFIGURES) $(TEXBASE).bbl: $(TEXFILE) $(BIBFILE)
lualatex $(TEXFILE) lualatex $(TEXFILE)
bibtex $(TEXBASE) bibtex $(TEXBASE)
lualatex $(TEXFILE) lualatex $(TEXFILE)
@ -50,17 +43,12 @@ $(TEXBASE).bbl: $(TEXFILE) $(BIBFILE) $(PDFFIGURES)
@sed -n -e '1,/You.ve used/p' $(TEXBASE).blg @sed -n -e '1,/You.ve used/p' $(TEXBASE).blg
pdf: $(PDFFILE) pdf: $(PDFFILE)
$(PDFFILE) : $(TEXFILE) $(PDFFIGURES) $(PDFFILE) : $(TEXFILE)
lualatex -interaction=scrollmode $< | tee /dev/stderr | fgrep -q "Rerun to get cross-references right" && lualatex -interaction=scrollmode $< || true lualatex -interaction=scrollmode $< | tee /dev/stderr | fgrep -q "Rerun to get cross-references right" && lualatex -interaction=scrollmode $< || true
again : again :
lualatex $(TEXFILE) lualatex $(TEXFILE)
supplement: supplement.pdf
supplement.pdf : supplement.tex
lualatex $<
lualatex $<
# watch files ####################################################### # watch files #######################################################
watchpdf : watchpdf :
while true; do ! make -s -q pdf && make pdf; sleep 0.5; done while true; do ! make -s -q pdf && make pdf; sleep 0.5; done
@ -121,7 +109,7 @@ $(REBUTTALPDFFILE) : $(REBUTTALTEXFILE)
lualatex -interaction=scrollmode $< | tee /dev/stderr | fgrep -q "Rerun to get cross-references right" && lualatex -interaction=scrollmode $< || true lualatex -interaction=scrollmode $< | tee /dev/stderr | fgrep -q "Rerun to get cross-references right" && lualatex -interaction=scrollmode $< || true
watchrebuttal : watchrebuttal :
while true; do ! make -s -q rebuttal && make rebuttal; sleep 0.5; done while true; do ! make -q rebuttal && make rebuttal; sleep 0.5; done
rebuttaldiff : rebuttaldiff :
latexdiff-git -r $(REBUTTALREVISION) --append-textcmd="response,issue" --pdf $(REBUTTALTEXFILE) latexdiff-git -r $(REBUTTALREVISION) --append-textcmd="response,issue" --pdf $(REBUTTALTEXFILE)
@ -179,7 +167,7 @@ help :
@echo -e \ @echo -e \
"make pdf: make the pdf file of the paper.\n"\ "make pdf: make the pdf file of the paper.\n"\
"make bib: run bibtex and make the pdf file of the paper.\n"\ "make bib: run bibtex and make the pdf file of the paper.\n"\
"make again: run lualatex and make the pdf file of the paper,\n"\ "make again: run pdflatex and make the pdf file of the paper,\n"\
" no matter whether you changed the .tex file or not.\n"\ " no matter whether you changed the .tex file or not.\n"\
"make watchpdf: make the pdf file of the paper\n"\ "make watchpdf: make the pdf file of the paper\n"\
" whenever the tex file is modified.\n"\ " whenever the tex file is modified.\n"\