Update README and Makefile for the latexmk existence check

Signed-off-by: Chun-Hung Tseng <henrybear327@gmail.com>
This commit is contained in:
Chun-Hung Tseng 2022-03-18 19:56:25 +01:00
parent d27d2c2301
commit 16fe2e9eb0
2 changed files with 3 additions and 0 deletions

View File

@ -2,6 +2,7 @@ PROJ = lkmpg
all: $(PROJ).pdf all: $(PROJ).pdf
$(PROJ).pdf: lkmpg.tex $(PROJ).pdf: lkmpg.tex
@if ! hash latexmk; then echo "No Latexmk found. See https://mg.readthedocs.io/latexmk.html for installation."; exit 1; fi
rm -rf _minted-$(PROJ) rm -rf _minted-$(PROJ)
latexmk -shell-escape lkmpg.tex -pdf latexmk -shell-escape lkmpg.tex -pdf

View File

@ -40,6 +40,8 @@ $ brew install --cask mactex
$ sudo tlmgr update --self $ sudo tlmgr update --self
``` ```
Note that `latexmk` is required to generated PDF, and it probably has been installed on your OS already. If not, please follow the [installation guide](https://mg.readthedocs.io/latexmk.html#installation).
Alternatively, using [Docker](https://docs.docker.com/) is recommended, as it guarantees the same dependencies with our GitHub Actions workflow. Alternatively, using [Docker](https://docs.docker.com/) is recommended, as it guarantees the same dependencies with our GitHub Actions workflow.
After install [docker engine](https://docs.docker.com/engine/install/) on your machine, pull the docker image [twtug/lkmpg](https://hub.docker.com/r/twtug/lkmpg) and run in isolated containers. After install [docker engine](https://docs.docker.com/engine/install/) on your machine, pull the docker image [twtug/lkmpg](https://hub.docker.com/r/twtug/lkmpg) and run in isolated containers.