Skip to content

Commit

Permalink
Makefile: check for vulnerabilities in used Go packages with govulnch…
Browse files Browse the repository at this point in the history
…eck when running `make check-all`

See https://go.dev/blog/vuln
  • Loading branch information
valyala committed Sep 8, 2022
1 parent f81dfaf commit 5dad557
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -338,7 +338,7 @@ errcheck: install-errcheck
install-errcheck:
which errcheck || GO111MODULE=off go get github.com/kisielk/errcheck

check-all: fmt vet lint errcheck golangci-lint
check-all: fmt vet lint errcheck golangci-lint govulncheck

test:
go test ./lib/... ./app/...
Expand Down Expand Up @@ -394,6 +394,12 @@ golangci-lint: install-golangci-lint
install-golangci-lint:
which golangci-lint || curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(shell go env GOPATH)/bin v1.48.0

govulncheck: install-govulncheck
govulncheck ./...

install-govulncheck:
which govulncheck || go install golang.org/x/vuln/cmd/govulncheck@latest

install-wwhrd:
which wwhrd || GO111MODULE=off go get github.com/frapposelli/wwhrd

Expand Down

0 comments on commit 5dad557

Please sign in to comment.