Skip to content

Commit

Permalink
Merge pull request #27 from project-kessel/snake-case-openapi
Browse files Browse the repository at this point in the history
Generate openapi component properties in snake_case
  • Loading branch information
randymgeorge authored Aug 8, 2024
2 parents d1300ff + 7a68767 commit 2dc7dfa
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ init:
api:
@echo "Generating api protos"
@$(DOCKER) build -t custom-protoc ./api
@$(DOCKER) run -t --rm -v $(PWD)/api:/api -v $(PWD)/openapi.yaml:/openapi.yaml -v $(PWD)/third_party:/third_party \
@$(DOCKER) run -t --rm -v $(PWD)/api:/api:rw,z -v $(PWD)/openapi.yaml:/openapi.yaml:rw,z -v $(PWD)/third_party:/third_party:ro,z \
-w=/api/ custom-protoc sh -c "buf generate && \
buf lint && \
buf breaking --against 'buf.build/project-kessel/inventory-api' "
Expand All @@ -36,7 +36,7 @@ api:
api_breaking:
@echo "Generating api protos, allowing breaking changes"
@$(DOCKER) build -t custom-protoc ./api
@$(DOCKER) run -t --rm -v $(PWD)/api:/api -v $(PWD)/openapi.yaml:/openapi.yaml -v $(PWD)/third_party:/third_party \
@$(DOCKER) run -t --rm -v $(PWD)/api:/api:rw,z -v $(PWD)/openapi.yaml:/openapi.yaml:rw,z -v $(PWD)/third_party:/third_party:ro,z \
-w=/api/ custom-protoc sh -c "buf generate && \
buf lint"

Expand Down
1 change: 1 addition & 0 deletions api/buf.gen.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ plugins:
opt:
- fq_schema_naming=true
- default_response=false
- naming=proto
- local: protoc-gen-validate
opt:
- paths=source_relative
Expand Down

0 comments on commit 2dc7dfa

Please sign in to comment.