summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile30
1 files changed, 19 insertions, 11 deletions
diff --git a/Makefile b/Makefile
index a0f2efc..620d0d8 100644
--- a/Makefile
+++ b/Makefile
@@ -1,4 +1,16 @@
-all: goimports vet
+all: bug.pb.go goimports vet
+ @echo This GO code passes the compile checks
+
+# fixes your numbers if you move things around
+# THIS TOTALLY BREAKS THE POINT OF PROTOBUF
+# To work around that breaking, you must change the version
+# also, all the wrapping code must support this. which it doesn't
+proto-renumber: clean
+ autogenpb --renumber --proto bug.proto
+ make goimports vet
+
+bug.pb.go: bug.proto
+ make generate
generate: clean
go mod init
@@ -6,19 +18,15 @@ generate: clean
go generate
go-generate:
- rm -f *.pb.go
-
-vet:
- @GO111MODULE=off go vet
- @echo this go library builds okay
+ rm -f *.pb.go *.patch
goimports:
goimports -w *.go
-proto: bug.pb.go
-
-bug.pb.go: bug.proto
- autogenpb --proto bug.proto
+vet:
+ @GO111MODULE=off go vet
clean:
- rm -f go.* *.pb.go
+ rm -f *.pb.go *.patch
+ -rm -f go.*
+ go-mod-clean purge