~chrisppy/go-barefeed

ref: 63fc114fd6c8a8779e44c7042a5c1a6f543a76fb go-barefeed/Makefile -rw-r--r-- 978 bytes
63fc114fChris Palmer updates from schema 5 months ago
                                                                                
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
32
33
34
35
36
37
38
39
40
41
42
43
44
.POSIX:
.SUFFIXES:

GO = go
RM = rm
GOFLAGS =

gosrc = $(shell find . -name '*.go')
gosrc += go.mod go.sum
goflags = $(GOFLAGS)

all: barefeed
barefeed: $(gosrc)
	$(GO) build $(goflags)
clean:
	$(GO) mod tidy
format:
	$(GO) fmt -x ./...
	$(GO) vet ./...
lint:
	$(GO) get -u golang.org/x/lint/golint
	$(GO) get -u honnef.co/go/tools/cmd/staticcheck
	$(GO) get -u gitlab.com/opennota/check/cmd/aligncheck
	$(GO) get -u gitlab.com/opennota/check/cmd/structcheck
	$(GO) get -u gitlab.com/opennota/check/cmd/varcheck
	$(GO) get -u github.com/kisielk/errcheck
	golint -set_exit_status ./...
	staticcheck ./...
	aligncheck ./...
	structcheck ./...
	varcheck ./...
	errcheck ./...
security:
	$(GO) get -u github.com/securego/gosec/cmd/gosec
	gosec -exclude=G107,G204 ./... 
dependencies:
	$(GO) get -u github.com/psampaz/go-mod-outdated
	$(GO) list -u -m -json all | go-mod-outdated -direct -ci
test:
	$(GO) test ./...
check: clean format lint security dependencies test 
	make clean