build.sh 417 B

12345678910111213
  1. export GOPATH=$PWD
  2. export PATH=$PATH:$PWD/bin
  3. export GOBIN=$PWD/bin
  4. go get github.com/golang/protobuf/protoc-gen-go
  5. go install ./src/github.com/golang/protobuf/protoc-gen-go
  6. export SNAKE_RPC_PATH=$PWD/snakesimulator
  7. mkdir -p $SNAKE_RPC_PATH
  8. rm -f $SNAKE_RPC_PATH/*.pb.go
  9. protoc -I$SNAKE_RPC_PATH --go_out=plugins=grpc:$SNAKE_RPC_PATH $SNAKE_RPC_PATH/snakesimulator.proto
  10. go get -v
  11. go build -o $GOBIN/snakesimulator