Skip to content
Snippets Groups Projects
vars 1.07 KiB
Newer Older
  • Learn to ignore specific revisions
  • VERSION != git tag | tail -1
    QR_TARGET != grep mailto: README.md | cut -d: -f2,3
    
    
    Malin Freeborn's avatar
    Malin Freeborn committed
    .check:
    	@command -v git >/dev/null || ( echo install git && exit 1 )
    	@command -v git-lfs >/dev/null || ( echo install git-lfs && exit 1 )
    	@command -v lualatex >/dev/null || ( echo install lualatex && exit 1 )
    	@command -v latexmk >/dev/null || ( echo install latexmk && exit 1 )
    	@command -v inkscape >/dev/null || ( echo install inkscape && exit 1 )
    
    
    COMPRESS = gs -sDEVICE=pdfwrite -dCompatibilityLevel=1.5 -dNOPAUSE -dQUIET -dBATCH -dPrinted=false -sOutputFile=$@ $<
    
    
    Malin Freeborn's avatar
    Malin Freeborn committed
    CP := ln -f
    BOOK := $(shell basename "$$(pwd)")
    
    LOCAL_DROSS := rubbish
    DROSS := ../$(LOCAL_DROSS)
    
    COMPILER := latexmk -file-line-error -auxdir=$(DROSS) -pdflua -interaction=nonstopmode -halt-on-error -shell-escape -r config/.latexmkrc -jobname=$(BOOK)
    
    RELEASE := $(BOOK)-$(VERSION).pdf
    
    Malin Freeborn's avatar
    Malin Freeborn committed
    GLOS := makeglossaries -d $(DROSS)
    RUN := lualatex -output-directory $(DROSS) -shell-escape
    
    CLEAN := $(RM) -r $(DROSS) $(LOCAL_DROSS) qr.tex *.pdf .switch-gls svg-inkscape
    
    DEPS := $(wildcard *.tex) $(wildcard config/*sty) config/ $(wildcard $(DROSS)/*.glg)