cosmos-sdk/scripts/protocgen.sh

13 lines
389 B
Bash
Raw Normal View History

#!/usr/bin/env bash
set -eo pipefail
proto_dirs=$(find . -path ./third_party -prune -o -name '*.proto' -print0 | xargs -0 -n1 dirname | sort | uniq)
for dir in $proto_dirs; do
protoc \
-I. \
2020-06-03 06:33:51 -07:00
--gocosmos_out=plugins=interfacetype+grpc,paths=source_relative,\
Mgoogle/protobuf/any.proto=github.com/cosmos/cosmos-sdk/codec/types:. \
2020-05-15 07:57:20 -07:00
$(find "${dir}" -maxdepth 1 -name '*.proto')
done