forked from inarts/Paper
-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathMakefile
40 lines (35 loc) · 1.28 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
-include lib/resources/build/Makefile
fixme:
@echo "Seems you forgot the checkout the 'lib' using the recursive parameter."
@echo "Fixing it for you..."
@git submodule update --init --recursive || git clone https://github.com/tubav/Core.git lib
.PHONY: html arxiv
git-diff:
@echo "TODO: move to library"
ifeq (, $(shell which latexpand))
tlmgr install latexpand
endif
ifeq (, $(shell which latexdiff))
tlmgr install latexdiff
endif
ifeq (, $(shell which git-latexdiff))
$(error "No git-latexdiff in $(PATH), you need to install it first")
endif
git-latexdiff --main template.tex --biber --run-biber -v HEAD --
arxiv:
@type arxiv-collector >/dev/null 2>&1 || (echo "Run 'pip3 install arxiv-collector' first." >&2 ; exit 1)
arxiv-collector template.tex
html:
@echo "TODO: move to library"
@echo "TODO: fix issues with subfigures"
@echo "TODO: fix issues with index"
@echo "TODO: enhance 'make clean'"
@echo "TODO: mention 'tlmgr install make4ht tex4ht'"
pdflatex template
pdflatex template
biber template
pdflatex template
make4ht -u -d html template "htmlimages,htmlcolor,html5,charset=utf-8,fn-in"
perl -i -0pe 's/<img.*\n.*alt="PICT".*//g' html/template.html
perl -i -0pe 's/<hr class=".*figure".*\/>//g' html/template.html
perl -i -0pe 's/<\?.*\n.*\n.*\n.*\n//' html/template.html