Add makefile

This commit is contained in:
Oystein Kristoffer Tveit 2020-05-24 23:12:29 +02:00
parent 4642375d95
commit 488364f68b
1 changed files with 22 additions and 0 deletions

22
Makefile Normal file
View File

@ -0,0 +1,22 @@
.DEFAULT_GOAL := main.pdf
main.pdf: main.tex jishoScrape/index.js title/titlepage.tex $(data)
for i in $$(seq 5 -1 1); do node jishoScrape/index.js n$$i; done
xelatex main.tex
#TODO: Make this modular, fix the index.js target.
jishoScrape/index.js: jishoScrape/index.js $(wildcard jishoScrape/src/*.js)
for i in $$(seq 1 5); do node jishoScrape/index.js n$$i; done
data/pages/n%.tex: data/txt/n%.txt
node jishoScrape/index.js n%
data/tables/n%.tex: data/txt/n%.txt
node jishoScrape/index.js n%
.PHONY: clean
clean:
rm data/pages/*
rm data/tables/*
rm main.aux main.log main.out main.toc main.synctex.gz