From 770931999918f4c62044c0e78a7d071b70e629be Mon Sep 17 00:00:00 2001 From: Adrian Chiris Date: Mon, 27 Feb 2023 15:23:51 +0200 Subject: [PATCH] Bump golangci-lint version (#77) typecheck seems to not play nice with go 1.20[1]. with the current version of golangci-lint we are using. bump to latest release. [1] https://github.com/golangci/golangci-lint/issues/3420 Signed-off-by: adrianc --- .golangci.yml | 11 +++-------- Makefile | 2 +- 2 files changed, 4 insertions(+), 9 deletions(-) diff --git a/.golangci.yml b/.golangci.yml index 35594e6e..ae58b4e1 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -25,13 +25,11 @@ linters-settings: min-complexity: 30 goimports: local-prefixes: github.com/Mellanox/ib-sriov-cni - golint: - min-confidence: 0 gomnd: settings: mnd: # don't include the "operation" and "assign" - checks: argument,case,condition,return + checks: [argument,case,condition,return] govet: check-shadowing: true settings: @@ -55,11 +53,11 @@ linters: disable-all: true enable: - bodyclose - - deadcode - depguard - dogsled - dupl - errcheck + - exportloopref - funlen - gochecknoinits - goconst @@ -67,7 +65,6 @@ linters: - gocognit - gofmt - goimports - - golint - gomnd - goprintffuncname - gosec @@ -78,16 +75,14 @@ linters: - misspell - nakedret - prealloc + - revive - rowserrcheck - - scopelint - staticcheck - - structcheck - stylecheck - typecheck - unconvert - unparam - unused - - varcheck - whitespace issues: diff --git a/Makefile b/Makefile index 8fde4edd..0447c651 100644 --- a/Makefile +++ b/Makefile @@ -43,7 +43,7 @@ GOLANGCI_LINT = $(GOBIN)/golangci-lint # golangci-lint version should be updated periodically # we keep it fixed to avoid it from unexpectedly failing on the project # in case of a version bump -GOLANGCI_LINT_VER = v1.46.2 +GOLANGCI_LINT_VER = v1.51.2 TIMEOUT = 15 Q = $(if $(filter 1,$V),,@)