-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
44 lines (36 loc) · 1.03 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
CC = crisscross
CCP = $(CC) process
CCPPLAIN = $(CCP) --no-yaml --no-render --no-open-text --no-open-ren
EXDIR = examples
APPDIR = $(EXDIR)/app
QUIZDIR = $(EXDIR)/quiz
LANGDIR = $(EXDIR)/lang
README = README.md
READMETEMP = README_template.md
exdoc:
cd $(APPDIR) && \
$(CCPPLAIN) $(READMETEMP) -o $(README)
cd $(LANGDIR) && \
$(CCPPLAIN) $(READMETEMP) -o $(README)
cd $(QUIZDIR) && \
$(CCPPLAIN) $(READMETEMP) -o $(README)
app:
cd $(APPDIR) && \
$(CCP) header.md template.md
lang:
cd $(LANGDIR) && \
$(CCP) a.md -o out/{{id}}.pdf
quiz:
cd $(QUIZDIR) && \
$(CC) combine yaml/101.yaml,yaml/102.yaml yaml/orig.yaml,yaml/soln.yaml -o yaml_combined/ && \
$(CCP) -V number:1 -V date:'Jan 1 2001' -y 'yaml_combined/*.yaml' template.md -o quizzes/quiz{{number}}_{{id}}.pdf -r rmarkdown
maindoc:
$(CC) process -h > help/process.md
$(CC) combine -h > help/combine.md
$(CCPPLAIN) $(READMETEMP) -o $(README)
docs: exdoc maindoc
all: app quiz lang docs
pypi:
rm -rf dist
python3 setup.py sdist bdist_wheel
python3 -m twine upload dist/*