-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
35 lines (27 loc) · 1004 Bytes
/
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
all: diagrams spec
tmpdir:
@mkdir -p tmp
diagrams: tmpdir
@echo Generating SVG diagrams...
@mmdc -i etc/test-object-state-machine.mmd -o etc/test-object-state-machine.svg
@mmdc -i etc/workflow.mmd -o etc/workflow.svg
includes: tmpdir
@echo Generating YAML fragments...
@bin/generate-test-plan-mnemonics.pl > tmp/test-plan-mnemonics.yaml
@bin/generate-input-parameter-schema.pl > tmp/input-parameters.yaml
@bin/generate-test-cases.pl > tmp/test-cases.yaml
@bin/generate-error-codes.pl > tmp/error-codes.yaml
spec: tmpdir includes
@echo Generating YAML file...
@gpp -x rst-api-spec.yaml.in > tmp/rst-api-spec.yaml
@echo Generating JSON file...
@yq -o=json eval tmp/rst-api-spec.yaml > tmp/rst-api-spec.json
static-html:
@echo Generating static HTML file...
@openapi-generator generate -g html -i tmp/rst-api-spec.yaml >/dev/null
@mv index.html tmp/rst-api-spec.html
lint:
@openapi-generator validate -i tmp/rst-api-spec.yaml
pages:
@echo Generating pages...
@bin/build-pages.sh