Skip to content

Commit

Permalink
tooling: generate protoset file (#17364)
Browse files Browse the repository at this point in the history
Extends the `proto` make target to generate a protoset file for use with
grpcurl etc.
  • Loading branch information
boxofrad authored Jun 26, 2023
1 parent b117eb0 commit ce24646
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions build-support/scripts/protobuf.sh
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,10 @@ function main {

status "Generated gRPC rate limit mapping file"

generate_protoset_file

status "Generated protoset file"

return 0
}

Expand Down Expand Up @@ -152,5 +156,11 @@ function generate_rate_limit_mappings {
}
}

function generate_protoset_file {
local pkg_dir="${SOURCE_DIR}/pkg"
mkdir -p "$pkg_dir"
print_run buf build -o "${pkg_dir}/consul.protoset"
}

main "$@"
exit $?

0 comments on commit ce24646

Please sign in to comment.