Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update golangci-lint #4636

Merged
merged 2 commits into from
Jun 28, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -145,8 +145,7 @@ test_sim_app_profile:
test_cover:
@export VERSION=$(VERSION); bash -x tests/test_cover.sh

lint: tools ci-lint
ci-lint:
alessio marked this conversation as resolved.
Show resolved Hide resolved
lint: golangci-lint
golangci-lint run
find . -name '*.go' -type f -not -path "./vendor*" -not -path "*.git*" | xargs gofmt -d -s
go mod verify
Expand Down
10 changes: 6 additions & 4 deletions contrib/devtools/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ endif

GOPATH ?= $(shell $(GO) env GOPATH)
GITHUBDIR := $(GOPATH)$(FS)src$(FS)github.com
GOLANGCI_LINT_VERSION := v1.16.0
GOLANGCI_LINT_HASHSUM := ac897cadc180bf0c1a4bf27776c410debad27205b22856b861d41d39d06509cf
GOLANGCI_LINT_VERSION := v1.17.1
GOLANGCI_LINT_HASHSUM := f5fa647a12f658924d9f7d6b9628d505ab118e8e049e43272de6526053ebe08d

###
# Functions
Expand Down Expand Up @@ -52,7 +52,7 @@ CLOG = $(TOOLS_DESTDIR)/clog
all: tools

tools: tools-stamp
tools-stamp: $(STATIK) $(GOIMPORTS) $(CLOG) $(GOLANGCI_LINT)
tools-stamp: $(STATIK) $(GOIMPORTS) $(CLOG)
touch $@

$(GOLANGCI_LINT): $(mkfile_dir)/install-golangci-lint.sh
Expand All @@ -62,11 +62,13 @@ $(STATIK):
$(call go_install,rakyll,statik,v0.1.5)

$(GOIMPORTS):
go get golang.org/x/tools/cmd/goimports@v0.0.0-20190114222345-bf090417da8b
go get golang.org/x/tools/cmd/goimports@v0.0.0-20190628034336-212fb13d595e

$(CLOG):
$(call go_install,alessio,clog,1)

golangci-lint: $(GOLANGCI_LINT)

tools-clean:
rm -f $(STATIK) $(GOIMPORTS) $(CLOG) $(GOLANGCI_LINT)
rm -f tools-stamp
Expand Down