summaryrefslogtreecommitdiff
path: root/Makefile
blob: b96172c637e220f78f7b46fec2bffcb6089d8ed3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
VERSION = $(shell git describe --tags)

# create the go.mod and go.sum if this is a brand new repo
# REDOMOD = $(shell if [ -e go.mod ]; then  echo go.mod; else echo no go mod; fi)
REDOMOD = $(shell if [ -e go.sum ]; then  echo go.sum exists; else GO111MODULE= go mod init; GO111MODULE= go mod tidy; fi)

all:
	GO111MODULE=off go vet

goimports:
	goimports -w *.go

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

clean:
	rm -f go.*