You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by ti...@apache.org on 2024/07/14 04:03:14 UTC

(pulsar-client-go) branch master updated: ci: validate multiple version builds and use golangci-lint-action (#1250)

This is an automated email from the ASF dual-hosted git repository.

tison pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/pulsar-client-go.git


The following commit(s) were added to refs/heads/master by this push:
     new 2ff2c2cd ci: validate multiple version builds and use golangci-lint-action (#1250)
2ff2c2cd is described below

commit 2ff2c2cdafe71d72a5d3b69680f3086301510f4b
Author: Zixuan Liu <no...@gmail.com>
AuthorDate: Sun Jul 14 12:03:08 2024 +0800

    ci: validate multiple version builds and use golangci-lint-action (#1250)
    
    * ci: validate multiple version builds and use golangci-lint-actio
    
    * Fix lint
---
 .github/workflows/ci.yml | 16 +++++++++++++---
 1 file changed, 13 insertions(+), 3 deletions(-)

diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 3a6731f9..e2eb9fa0 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -20,25 +20,35 @@ on: [pull_request]
 jobs:
   build:
     runs-on: ubuntu-latest
+    strategy:
+      matrix:
+        go-version: [ '1.20', '1.21', '1.22' ]
     steps:
       - uses: actions/checkout@v3
-      - uses: actions/setup-go@v3
+      - uses: actions/setup-go@v5
+        with:
+          go-version: ${{ matrix.go-version }}
       - run: make build
 
   lint:
     runs-on: ubuntu-latest
     steps:
       - uses: actions/checkout@v3
+      - uses: actions/setup-go@v5
+        with:
+          go-version: '1.20'
       - name: Check license header
         run: docker run --rm -v $(pwd):/github/workspace ghcr.io/korandoru/hawkeye-native:v3 check
       - name: Run golangci-lint
-        run: make lint
+        uses: golangci/golangci-lint-action@v6
+        with:
+          version: v1.51.2
 
   integration-tests:
     runs-on: ubuntu-latest
     strategy:
       matrix:
-        go-version: ['1.20', '1.21.0', '1.22.0']
+        go-version: [ '1.20', '1.21', '1.22' ]
     steps:
       - uses: actions/checkout@v3
       - name: clean docker cache