From eb82b2c00c7acefb2cf2fbc4f163e63f8fa71834 Mon Sep 17 00:00:00 2001 From: Valentin Kiselev Date: Fri, 26 Jul 2024 10:39:29 +0300 Subject: [PATCH] ci: use go.mod as go version --- .github/workflows/lint.yml | 2 +- .github/workflows/release.yml | 2 ++ .github/workflows/test.yml | 6 ++++++ 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 1e389936..6dc75466 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -13,7 +13,7 @@ jobs: - name: Install Go uses: actions/setup-go@v5 with: - go-version: 1.22.x + go-version-file: go.mod - uses: actions/checkout@v4 - name: golangci-lint uses: golangci/golangci-lint-action@v4 diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index a7d66646..bb6ddd23 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -22,6 +22,8 @@ jobs: - name: Set up Go uses: actions/setup-go@v5 + with: + go-version-file: go.mod - name: Install Snapcraft uses: samuelmeuli/action-snapcraft@v1 diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 8cf25021..05f5dd11 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -14,6 +14,8 @@ jobs: steps: - name: Install Go uses: actions/setup-go@v5 + with: + go-version-file: go.mod - name: Checkout code uses: actions/checkout@v4 - name: Test @@ -35,6 +37,8 @@ jobs: steps: - name: Install Go uses: actions/setup-go@v5 + with: + go-version-file: go.mod - name: Checkout code uses: actions/checkout@v4 - name: Prepare lefthook @@ -63,6 +67,8 @@ jobs: steps: - name: Install Go uses: actions/setup-go@v5 + with: + go-version-file: go.mod - name: Checkout code uses: actions/checkout@v4 - name: Build binaries