From 493af18617ad5191f6cb087c420b825890a7404b Mon Sep 17 00:00:00 2001 From: Enrique Llorente Date: Thu, 7 Sep 2023 11:42:58 +0200 Subject: [PATCH] lint: Increase timeout to 5m Signed-off-by: Enrique Llorente --- .github/workflows/main.yml | 6 ++---- hack/lint.sh | 9 ++++----- 2 files changed, 6 insertions(+), 9 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index faf66be3..ca5421cf 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -17,10 +17,8 @@ jobs: uses: actions/setup-go@v1 with: go-version: ${{ steps.go-version.outputs.minimal }} - - name: golangci-lint - uses: golangci/golangci-lint-action@v2 - with: - version: v1.42.1 + - name: Run lint + run: make lint build: runs-on: ubuntu-latest steps: diff --git a/hack/lint.sh b/hack/lint.sh index d7e6b849..fe206bab 100755 --- a/hack/lint.sh +++ b/hack/lint.sh @@ -1,8 +1,7 @@ #!/bin/bash -xe -golangci_lint_version=v1.42.1 -if [ ! -f $(go env GOPATH)/bin/golangci-lint ]; then - curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin $golangci_lint_version -fi -golangci-lint run +version=v1.42.1 +timeout=5m + +go run github.com/golangci/golangci-lint/cmd/golangci-lint@$version run --timeout $timeout