Newer
Older
# specify same name as in paper/Makefile
FILE=rsabsence
## build locally
local:
-cd paper && make pdf clean
-mv paper/$(FILE).pdf ./
## build docker image (requires root access for docker)
dbuild: Dockerfile
docker build \
-t $(FILE) .
## run docker image that produces *tex* from within docker
## and compiles to *pdf* outside docker
docker: dbuild
docker run \
--rm \
--env FILE=$(FILE) \
-v $(CURDIR):/output \
$(FILE)
## compile pdf using LaTeX outside docker
mv $(FILE).tex paper/
mkdir -p paper/figure
mv figure/* paper/figure
rmdir figure/
cd paper && make pdf2 clean