diff options
author | Robert Alessi <alessi@robertalessi.net> | 2019-03-05 21:16:48 +0100 |
---|---|---|
committer | Robert Alessi <alessi@robertalessi.net> | 2019-03-05 21:16:48 +0100 |
commit | da60a4f5c772acb67e5ed681d2335651d1dbbcd6 (patch) | |
tree | 1eb89357441797d9f5cec51d41de396a1b9c1671 /Makefile | |
parent | 144c4c8662089094eac38d906f571e3f5aefbee6 (diff) | |
download | icite-da60a4f5c772acb67e5ed681d2335651d1dbbcd6.tar.gz |
done documenting icite
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 36 |
1 files changed, 22 insertions, 14 deletions
@@ -5,24 +5,28 @@ VERS = $(shell ltxfileinfo -v $(NAME).dtx|sed -e 's/^v//') | |||
5 | LOCAL = $(shell kpsewhich --var-value TEXMFLOCAL) | 5 | LOCAL = $(shell kpsewhich --var-value TEXMFLOCAL) |
6 | UTREE = $(shell kpsewhich --var-value TEXMFHOME) | 6 | UTREE = $(shell kpsewhich --var-value TEXMFHOME) |
7 | all: $(NAME).pdf | 7 | all: $(NAME).pdf |
8 | test -e README.txt && mv README.txt README || exit 0 | 8 | # test -e README.md || exit 0 |
9 | $(NAME).pdf: $(NAME).dtx | 9 | $(NAME).pdf: $(NAME).dtx |
10 | lualatex --shell-escape --recorder --interaction=batchmode $(NAME).dtx >/dev/null | 10 | lualatex --shell-escape --recorder --interaction=batchmode $(NAME).dtx >/dev/null |
11 | biber $(NAME) >/dev/null | 11 | biber $(NAME) >/dev/null |
12 | if [ -f $(NAME).glo ]; then makeindex -q -s gglo.ist -o $(NAME).gls $(NAME).glo; fi | 12 | if [ -f $(NAME).glo ]; then makeindex -q -s gglo.ist -o $(NAME).gls $(NAME).glo; fi |
13 | if [ -f $(NAME).idx ]; then makeindex -q -s gind.ist -o $(NAME).ind $(NAME).idx; fi | 13 | if [ -f $(NAME).idx ]; then makeindex -q -s gind.ist -o $(NAME).ind $(NAME).idx; fi |
14 | texindy loccit.idx >/dev/null | 14 | if [ -f loccit.idx ]; then texindy -M icite.xdy loccit.idx >/dev/null; fi |
15 | if [ -f primary.idx ]; then texindy -M icite.xdy primary.idx >/dev/null; fi | ||
15 | lualatex --shell-escape --recorder --interaction=nonstopmode $(NAME).dtx > /dev/null | 16 | lualatex --shell-escape --recorder --interaction=nonstopmode $(NAME).dtx > /dev/null |
16 | lualatex --shell-escape --recorder --interaction=nonstopmode $(NAME).dtx > /dev/null | 17 | lualatex --shell-escape --recorder --interaction=nonstopmode $(NAME).dtx > /dev/null |
17 | clean: | 18 | lualatex: |
18 | rm -f $(NAME).{aux,fls,glo,gls,hd,idx,ilg,ind,log,out,toc,listing,bcf,bib,bbl,blg,run.xml} | 19 | lualatex --shell-escape --recorder --interaction=batchmode $(NAME).dtx >/dev/null |
19 | rm -f loccit.* | 20 | clean: lualatex |
21 | rm -f $(NAME).{aux,fls,glo,gls,hd,idx,ilg,ind,log,out,toc,xdy,listing,bcf,bib,bbl,blg,run.xml} | ||
22 | rm -f loccit.* primary.* | ||
20 | rm -f *~ | 23 | rm -f *~ |
21 | rm -rf auto/ | 24 | rm -rf auto/ |
22 | distclean: clean uninst | 25 | distclean: clean uninst |
23 | rm -rf _minted-* | 26 | rm -rf _minted-* |
24 | rm -f $(NAME).{pdf,sty} README | 27 | rm -f $(NAME).{pdf,sty} |
25 | rm -f *.zip *.tar.gz | 28 | rm -f *.zip *.tar.gz |
29 | pandoc -s README.md -o about.html | ||
26 | inst: uninst all | 30 | inst: uninst all |
27 | mkdir -p $(UTREE)/{tex,source,doc}/latex/$(NAME) | 31 | mkdir -p $(UTREE)/{tex,source,doc}/latex/$(NAME) |
28 | cp $(NAME).dtx $(UTREE)/source/latex/$(NAME) | 32 | cp $(NAME).dtx $(UTREE)/source/latex/$(NAME) |
@@ -34,25 +38,29 @@ local: uninst | |||
34 | cp $(NAME).sty $(UTREE)/tex/latex/$(NAME) | 38 | cp $(NAME).sty $(UTREE)/tex/latex/$(NAME) |
35 | uninst: | 39 | uninst: |
36 | rm -rf $(UTREE)/{tex,source,doc}/latex/$(NAME) | 40 | rm -rf $(UTREE)/{tex,source,doc}/latex/$(NAME) |
37 | #install: all | 41 | install: all |
38 | # sudo mkdir -p $(LOCAL)/{tex,source,doc}/latex/$(NAME) | 42 | sudo mkdir -p $(LOCAL)/{tex,source,doc}/latex/$(NAME) |
39 | # sudo cp $(NAME).dtx $(LOCAL)/source/latex/$(NAME) | 43 | sudo cp $(NAME).dtx $(LOCAL)/source/latex/$(NAME) |
40 | # sudo cp $(NAME).sty $(LOCAL)/tex/latex/$(NAME) | 44 | sudo cp $(NAME).sty $(LOCAL)/tex/latex/$(NAME) |
41 | # sudo cp $(NAME).pdf $(LOCAL)/doc/latex/$(NAME) | 45 | sudo cp $(NAME).pdf $(LOCAL)/doc/latex/$(NAME) |
46 | uninstall: | ||
47 | rm -rf $(LOCAL)/{tex,source,doc}/latex/$(NAME) | ||
42 | zip: all | 48 | zip: all |
43 | ln -sf . $(NAME) | 49 | ln -sf . $(NAME) |
44 | zip -Drq $(PWD)/$(NAME)-$(VERS).zip $(NAME)/{README,$(NAME).{pdf,dtx}} | 50 | zip -Drq $(PWD)/$(NAME)-$(VERS).zip $(NAME)/{README.md,$(NAME).{pdf,dtx,ins}} |
45 | rm $(NAME) | 51 | rm $(NAME) |
46 | package: distclean all | 52 | package: distclean all |
47 | mkdir $(NAME)/ | 53 | mkdir $(NAME)/ |
48 | cp README $(NAME).{dtx,ins,pdf} $(NAME)/ | 54 | cp Makefile README.md $(NAME).{dtx,ins,pdf} $(NAME)/ |
49 | mkdir -p tex/latex/$(NAME)/ | 55 | mkdir -p tex/latex/$(NAME)/ |
50 | cp $(NAME).sty tex/latex/$(NAME)/ | 56 | cp $(NAME).sty tex/latex/$(NAME)/ |
51 | mkdir -p doc/latex/$(NAME)/ | 57 | mkdir -p doc/latex/$(NAME)/ |
52 | cp $(NAME).pdf doc/latex/$(NAME)/ | 58 | cp $(NAME).pdf doc/latex/$(NAME)/ |
53 | mkdir -p source/latex/$(NAME)/ | 59 | mkdir -p source/latex/$(NAME)/ |
54 | cp Makefile README $(NAME).{dtx,ins} source/latex/$(NAME)/ | 60 | cp Makefile README.md $(NAME).{dtx,ins} source/latex/$(NAME)/ |
55 | zip -r $(NAME).tds.zip tex doc source | 61 | zip -r $(NAME).tds.zip tex doc source |
56 | rm -rf tex/ source/ doc/ | 62 | rm -rf tex/ source/ doc/ |
57 | tar czf $(NAME)-$(VERS).tar.gz $(NAME).tds.zip $(NAME)/ | 63 | tar czf $(NAME)-$(VERS).tar.gz $(NAME).tds.zip $(NAME)/ |
58 | rm -rf $(NAME)/ | 64 | rm -rf $(NAME)/ |
65 | |||
66 | .PHONY: all clean lualatex distclean inst local uninst install uninstall zip package | ||