use go generate instead of make for protoc

main
Jeffrey Paul 2 years ago
parent a1fa0d8fe5
commit b263706342
  1. 14
      Makefile
  2. 0
      mfer/.keep
  3. 3
      proto/gen.go
  4. 0
      proto/mf.proto

@ -1,2 +1,12 @@
mfer/app.pb.go: mf.proto
protoc --go_out=./mfer $<
PROTOC_GEN_GO := $(GOPATH)/bin/protoc-gen-go
default: compile
$(PROTOC_GEN_GO):
go get -u github.com/golang/protobuf/protoc-gen-go
compile: $(PROTOC_GEN_GO)
cd proto && go generate .
clean:
rm -rfv proto/*.pb.go

@ -0,0 +1,3 @@
package proto
//go:generate protoc --go_out=. mf.proto
Loading…
Cancel
Save