Rust grpc builder ()

My attempt after reading many online documentations

Reviewed-on: 
Co-authored-by: Quaternions <krakow20@gmail.com>
Co-committed-by: Quaternions <krakow20@gmail.com>
This commit is contained in:
2024-02-20 04:51:58 +00:00
committed by itzaname
parent 91df514bd6
commit db2e2e990f
2 changed files with 52 additions and 0 deletions

12
scripts/rust-gen.sh Normal file

@ -0,0 +1,12 @@
#!/bin/bash
for f in *.proto
do
name=$(basename $f .proto)
mkdir -p ./rust-grpc/$name
protoc \
--prost_out=./rust-grpc/$name \
--tonic_out=./rust-grpc/$name \
$f
#protoc --experimental_allow_proto3_optional --rust_out=./rust-grpc/$name --rust_opt=paths=source_relative --rust-grpc_out=./rust-grpc/$name --rust-grpc_opt=paths=source_relative
done