summaryrefslogtreecommitdiff
path: root/Makefile
blob: 2413c561466946016654f69cae1846d7178faad0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
# You must use the current protoc-gen-go
#
# go-clone --go-src google.golang.org/protobuf
# cd ~/go/src/google.golang.org/protobuf/cmd/protoc-gen-go
# go install


all: package.pb.go machine.pb.go goimports vet

vet:
	@GO111MODULE=off go vet
	@echo this go library package builds okay

# autofixes your import headers in your golang files
goimports:
	goimports -w *.go

redomod:
	rm -f go.*
	GO111MODULE= go mod init
	GO111MODULE= go mod tidy

clean:
	rm -f *.pb.go
	-rm -f go.*

package.pb.go: package.proto
	autogenpb --proto package.proto

machine.pb.go: machine.proto
	autogenpb --proto machine.proto