Skip to content

Commit d7df1b4

Browse files
committed
Merge pull request #263 from vbatts/printable
*: printable documents
2 parents 9ffb3ef + 4ee036f commit d7df1b4

File tree

1 file changed

+43
-0
lines changed

1 file changed

+43
-0
lines changed

Makefile

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
2+
DOCKER ?= $(shell which docker)
3+
DOC_FILES := \
4+
README.md \
5+
code-of-conduct.md \
6+
principles.md \
7+
ROADMAP.md \
8+
implementations.md \
9+
bundle.md \
10+
runtime.md \
11+
runtime-linux.md \
12+
config.md \
13+
config-linux.md \
14+
runtime-config.md \
15+
runtime-config-linux.md
16+
17+
docs: pdf html
18+
19+
pdf:
20+
@mkdir -p output/ && \
21+
$(DOCKER) run \
22+
-it \
23+
--rm \
24+
-v $(shell pwd)/:/input/:ro \
25+
-v $(shell pwd)/output/:/output/ \
26+
-u $(shell id -u) \
27+
vbatts/pandoc -f markdown_github -t latex -o /output/docs.pdf $(patsubst %,/input/%,$(DOC_FILES)) && \
28+
ls -sh $(shell readlink -f output/docs.pdf)
29+
30+
html:
31+
@mkdir -p output/ && \
32+
$(DOCKER) run \
33+
-it \
34+
--rm \
35+
-v $(shell pwd)/:/input/:ro \
36+
-v $(shell pwd)/output/:/output/ \
37+
-u $(shell id -u) \
38+
vbatts/pandoc -f markdown_github -t html5 -o /output/docs.html $(patsubst %,/input/%,$(DOC_FILES)) && \
39+
ls -sh $(shell readlink -f output/docs.html)
40+
41+
clean:
42+
rm -rf output/ *~
43+

0 commit comments

Comments
 (0)