-
Notifications
You must be signed in to change notification settings - Fork 3
/
Makefile
61 lines (50 loc) · 1.31 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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
OPENAPI_GENERATOR_VERSION ?= v6.4.0
OPENAPI_SPEC_PATH ?= openapi.json
GENERATE_CONFIG_PATH ?= generate/config.yaml
GENERATE_TEMPLATES_PATH ?= generate/templates
OUTPUT_PATH ?= .
.PHONY: delete-generated generate clean build build-prod regen
regen: delete-generated generate format clean
regen-bin: delete-generated generate format clean build
delete-generated:
rm -rf \
docs \
src/Vault/Model \
src/Vault.Test/Model \
build.bat \
build.sh \
git_push.sh \
mono_nunit_test.sh \
VaultClient.sln \
.gitignore \
.openapi-generator \
.travis.yml
generate:
docker run \
--rm \
--volume "${PWD}:/local" \
--user="$(shell id -u):$(shell id -g)" \
openapitools/openapi-generator-cli:$(OPENAPI_GENERATOR_VERSION) generate \
--generator-name csharp-netcore \
--engine "handlebars" \
--input-spec /local/$(OPENAPI_SPEC_PATH) \
--config /local/$(GENERATE_CONFIG_PATH) \
--template-dir /local/$(GENERATE_TEMPLATES_PATH) \
--output /local/$(OUTPUT_PATH) \
clean:
dotnet clean
rm -rf \
build.bat \
build.sh \
git_push.sh \
mono_nunit_test.sh \
.openapi-generator \
.travis.yml
build:
dotnet build
build-prod:
dotnet build -c release
format:
dotnet format
format-readme:
prettier --write README.md