witProtobuf/Makefile

32 lines
715 B
Makefile

all:
# You must use the current protoc-gen-go
#
# apt remove golang-goprotobuf-dev
#
# Then:
# go get -u github.com/golang/protobuf/protoc-gen-go
# cd ~/go/src/github.com/golang/protobuf/protoc-gen-go
# go install
events.pb.go: events.proto
# go get -u github.com/golang/protobuf/protoc-gen-go
# you probably also want to do:
# apt remove golang-goprotobuf-dev
# and use the one you built instead
# protoc --version 3.6++ does not mean that protoc will generate version3 .go files
protoc --version
protoc --go_out=. events.proto
compile:
protoc --go_out=. *.proto
deps:
apt install golang-goprotobuf-dev
apt install protobuf-compiler
push:
git pull
git add --all
git commit -a -s
git push