diff options
author | Robert Alessi <alessi@robertalessi.net> | 2019-07-29 12:46:29 +0200 |
---|---|---|
committer | Robert Alessi <alessi@robertalessi.net> | 2019-07-29 12:46:29 +0200 |
commit | 667223ce9716ce59965fb116f9707bc997893b44 (patch) | |
tree | b700ae20476f9da0e212c0c82ebac4b60fad8d03 /makefile | |
parent | a172bf8673ccbe0b5fec668329cb7b4e8e08c9da (diff) | |
download | oldstandard-667223ce9716ce59965fb116f9707bc997893b44.tar.gz |
updated oldstandard.tex and makefile
Diffstat (limited to 'makefile')
-rw-r--r-- | makefile | 33 |
1 files changed, 22 insertions, 11 deletions
@@ -1,31 +1,42 @@ | |||
1 | pkg := oldstandard | 1 | pkg := oldstandard |
2 | ver := $(shell grep '\\edef\\pkgver' $(pkg).tex | grep -Eo '[0-9]?\.[0-9]?') | 2 | ver := $(shell grep '\\edef\\pkgver' $(pkg).tex | grep -Eo '[0-9]{1,}\.[0-9]{1,}[a-z]{,1}') |
3 | TEXMFDIR := $(shell kpsewhich -expand-var='$$TEXMFHOME') | 3 | TEXMFDIR := $(shell kpsewhich -expand-var='$$TEXMFHOME') |
4 | HOMEDIR := $$HOME | 4 | HOMEDIR := $$HOME |
5 | LOCALFONTDIR := $(HOMEDIR)/.local/share/fonts | 5 | LOCALFONTDIR := $(HOMEDIR)/.local/share/fonts |
6 | 6 | ||
7 | doc: local | 7 | doc: local |
8 | lualatex --shell-escape $(pkg).tex | 8 | @echo "Building the documentation. Please wait..." |
9 | biber $(pkg) | 9 | lualatex --shell-escape $(pkg).tex >/dev/null |
10 | lualatex --shell-escape $(pkg).tex | 10 | biber $(pkg) >/dev/null |
11 | lualatex --shell-escape $(pkg).tex | 11 | lualatex --shell-escape $(pkg).tex >/dev/null |
12 | lualatex --shell-escape $(pkg).tex >/dev/null | ||
13 | @echo "Removing OldStandard .otf files from $(LOCALFONTDIR)..." | ||
14 | rm -f $(LOCALFONTDIR)/OldStandard-*.otf | ||
15 | luaotfload-tool --update | ||
16 | @echo "Done." | ||
12 | 17 | ||
13 | all: doc | 18 | all: doc |
14 | 19 | ||
15 | local: clean | 20 | local: |
21 | @rm -f $(LOCALFONTDIR)/OldStandard-*.otf | ||
22 | @echo "Installing latest OldStandard .otf files in $(LOCALFONTDIR)..." | ||
16 | cp otf/OldStandard-*.otf $(LOCALFONTDIR)/ | 23 | cp otf/OldStandard-*.otf $(LOCALFONTDIR)/ |
17 | luaotfload-tool --update | 24 | luaotfload-tool --update |
25 | @echo "Done." | ||
18 | 26 | ||
19 | package: doc | 27 | package: doc |
20 | mkdir $(pkg) | 28 | mkdir $(pkg)-$(ver) |
21 | cp *.{txt,md,tex,pdf} $(pkg) | 29 | cp *.{txt,md,tex,pdf} $(pkg)-$(ver) |
22 | cp otf/*.otf $(pkg) | 30 | cp otf/*.otf $(pkg)-$(ver) |
23 | tar czf $(pkg)-$(ver).tar.gz $(pkg) | 31 | tar czf $(pkg)-$(ver).tar.gz $(pkg)-$(ver) |
32 | @echo "$(pkg)-$(ver).tar.gz has been created." | ||
24 | 33 | ||
25 | clean: | 34 | clean: |
35 | @echo "Removing OldStandard .otf files from $(LOCALFONTDIR)..." | ||
26 | rm -f $(LOCALFONTDIR)/OldStandard-*.otf | 36 | rm -f $(LOCALFONTDIR)/OldStandard-*.otf |
27 | luaotfload-tool --update | 37 | luaotfload-tool --update |
28 | git clean -df | 38 | git clean -df |
29 | pandoc README.md -o about.html | 39 | pandoc README.md -o about.html |
40 | @echo "Done." | ||
30 | 41 | ||
31 | .PHONY: doc all local package clean prepare | 42 | .PHONY: doc all local package clean |