19 lines
503 B
Makefile
19 lines
503 B
Makefile
.PHONY: all clean
|
|
|
|
HTMLS = $(patsubst notebooks/%.ipynb,html/%.html,$(wildcard notebooks/*.ipynb))
|
|
|
|
badmathjax = "file:\/\/\/usr\/share\/javascript\/mathjax\/MathJax.js?config=TeX-AMS_CHTML-full,Safe"
|
|
goodmathjax = "https:\/\/cdn.jsdelivr.net\/npm\/mathjax@2\/MathJax.js?config=TeX-AMS_CHTML"
|
|
|
|
all: $(HTMLS)
|
|
|
|
clean:
|
|
rm -r html
|
|
|
|
html/%.html: notebooks/%.ipynb | html
|
|
jupyter nbconvert --to html $< --output $@ --execute --output-dir=.
|
|
sed -i 's/$(badmathjax)/$(goodmathjax)/' $@
|
|
|
|
html:
|
|
mkdir -p html
|