Skip to content

Commit 1d0da32

Browse files
authored
build: OpenAPI spec formatting (#54)
Adds formatting for the OpenAPI JSON and YAML files in order to make them easier to read and diff. PLAT-86
1 parent 6af3a6c commit 1d0da32

File tree

7 files changed

+44035
-18458
lines changed

7 files changed

+44035
-18458
lines changed

api/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ include ../tools.mk
33
.PHONY: generate-v1
44
generate-v1:
55
goa gen github.com/pgEdge/control-plane/api/v1/design -o v1
6+
$(yamlfmt) $(CURDIR)/v1/gen/http/*.yaml
67

78
.PHONY: generate
89
generate: generate-v1

api/v1/design/api.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ var _ = g.API("control-plane", func() {
1919
})
2020
})
2121
g.Meta("openapi:operationId", "{method}")
22+
g.Meta("openapi:json:indent", " ")
2223

2324
// Common errors
2425
g.Error("cluster_already_initialized", APIError)

api/v1/gen/http/openapi.json

Lines changed: 10895 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)