mirror of https://github.com/zcash/zips.git
Merge pull request #311 from nathan-at-least/render-via-docker
Support rendering via Docker.
This commit is contained in:
commit
901c1a7963
|
@ -0,0 +1,17 @@
|
|||
FROM debian:latest
|
||||
|
||||
RUN apt-get update \
|
||||
&& apt-get install -y \
|
||||
gawk \
|
||||
biber \
|
||||
latexmk \
|
||||
perl \
|
||||
python3 \
|
||||
python-pip \
|
||||
texlive-bibtex-extra \
|
||||
texlive-generic-recommended
|
||||
|
||||
RUN pip install rst2html5
|
||||
|
||||
WORKDIR "/zips"
|
||||
ENTRYPOINT ["make"]
|
9
Makefile
9
Makefile
|
@ -2,11 +2,16 @@
|
|||
# sudo apt-get install python-pip
|
||||
# sudo pip install rst2html5
|
||||
|
||||
.PHONY: all
|
||||
all:
|
||||
.PHONY: all all-zips protocol
|
||||
all-zips:
|
||||
$(MAKE) README.rst
|
||||
$(MAKE) index.html $(addsuffix .html,$(filter-out README,$(basename $(wildcard *.rst))))
|
||||
|
||||
all: all-zips protocol
|
||||
|
||||
protocol:
|
||||
$(MAKE) -C protocol
|
||||
|
||||
index.html: README.rst
|
||||
$(eval TITLE::=$(shell echo '$(basename $<)' | sed -r 's|zip-0{0,3}|ZIP |'): $(shell grep -E '^(\.\.)?\s*Title:' $< |sed 's|.*Title:\s*||'))
|
||||
rst2html5 -v --title="$(TITLE)" $< >$@
|
||||
|
|
|
@ -0,0 +1,7 @@
|
|||
#!/bin/bash
|
||||
set -efuxo pipefail
|
||||
|
||||
TAG='zcash-zips-render'
|
||||
|
||||
docker build -t "$TAG" .
|
||||
docker run -v "$(pwd):/zips" "$TAG"
|
Loading…
Reference in New Issue