Skip to content

Commit

Permalink
Fix CI: golint -> golangci-lint
Browse files Browse the repository at this point in the history
  • Loading branch information
creasty committed Mar 13, 2023
1 parent bf90154 commit 325dfb4
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
6 changes: 5 additions & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,11 @@ jobs:
key: go-mod-v4-{{ checksum "go.sum" }}
paths:
- "/go/pkg/mod"
- run: go get -u golang.org/x/lint/golint
- run:
name: Install golangci-lint
command: |
curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh \
| sh -s -- -b "$(go env GOPATH)/bin" v1.51.2
- run:
name: Run tests
command: make ci-test
Expand Down
3 changes: 1 addition & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,7 @@ SRC_FILES := $(shell find . -name '*.go' -not -path './vendor/*')
.PHONY: lint
lint:
@gofmt -e -d -s $(SRC_FILES) | awk '{ e = 1; print $0 } END { if (e) exit(1) }'
@echo $(SRC_FILES) | xargs -n1 golint -set_exit_status
@go vet $(PACKAGE_DIRS)
@golangci-lint --disable errcheck,unused run

.PHONY: test
test: lint
Expand Down

0 comments on commit 325dfb4

Please sign in to comment.