updateproto.sh 440 B

1234567891011121314
  1. export GOBIN=$(go env GOPATH)/bin
  2. export PATH=$PATH:$GOBIN
  3. export RPC_PATH=$PWD/remotecontrol
  4. go install google.golang.org/protobuf/compiler/protogen
  5. mkdir -p $RPC_PATH
  6. rm -f $RPC_PATH/*.pb.go
  7. protoc -I$RPC_PATH --go_out=plugins=grpc:$RPC_PATH $RPC_PATH/remotecontrol.proto
  8. # Cluster interface
  9. export CUSTER_PATH=$PWD/cluster
  10. rm -f $CUSTER_PATH/*.pb.go
  11. protoc -I$CUSTER_PATH --go_out=plugins=grpc:$CUSTER_PATH $CUSTER_PATH/cluster.proto