elliots / protoc-gen-twirp_swagger

Swagger generator for twirp

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Multiple swagger.json files generated

RoarkeRandall opened this issue · comments

if you split out your protobuf definition into multiple files, so something like:

  • messages.proto
  • services.proto

then a json file will be generated per proto file.

I don't really know swagger at all (yet), but I think it expects a single json file

Does the services one contain all the messages?

I'm currently merging many swagger files together with jq... not pretty but getting the job done.

j=`jq -s '.[0] * .[1]' $ALL_SCHEMAS_FILE $CURRENT_API_FILE`
echo $j > $ALL_SCHEMAS_FILE