From 238dd63d17dcff6909ab15c84d3f41ef39edfe04 Mon Sep 17 00:00:00 2001 From: Deividas Petraitis Date: Mon, 5 May 2025 14:09:39 +0300 Subject: [PATCH] BE-730 | golangci-lint use toolchain of current go.mod version --- Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index aadb078e8..c89d9e6ed 100644 --- a/Makefile +++ b/Makefile @@ -9,6 +9,7 @@ export OSTYPE := $(shell uname -s) VERSION := $(shell echo $(shell git describe --tags) | sed 's/^v//') COMMIT := $(shell git log -1 --format='%H') GO_VERSION := $(shell cat go.mod | grep -E 'go [0-9].[0-9]+' | cut -d ' ' -f 2) +GOTOOLCHAIN := go$(GO_VERSION) PACKAGES_UNIT=$(shell go list ./...) DOCKER := $(shell which docker) BUILDDIR ?= $(CURDIR)/build @@ -58,7 +59,7 @@ all-start: osmosis-start run lint: @echo "--> Running linter" - golangci-lint run --timeout=10m + GOTOOLCHAIN=$(GOTOOLCHAIN) golangci-lint run --timeout=10m test-unit: @VERSION=$(VERSION) go test -mod=readonly $(PACKAGES_UNIT)