Skip to content

Commit

Permalink
Update golangci-lint to v1.45.2 and actions to latest
Browse files Browse the repository at this point in the history
The golangci/golangci-lint-action@v2 implicitly installs Go and its
version was recently upgraded to Go 1.18. It causes an issue for old
golangci-lint. To fix the problem either upgrading
golangci-lint-action@v3 and setup Go 1.17.x explicitly or updating
golangci-lint to the latest v1.45.2. I fixed both and also upgrading
some actions to the latest.
  • Loading branch information
minamijoyo committed Apr 14, 2022
1 parent f6ba9f1 commit 01f149d
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 6 deletions.
9 changes: 6 additions & 3 deletions .github/workflows/lint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,11 @@ jobs:
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- uses: actions/setup-go@v3
with:
go-version: 1.17.8
- name: golangci-lint
uses: golangci/golangci-lint-action@v2
uses: golangci/golangci-lint-action@v3
with:
version: v1.43.0
version: v1.45.2
6 changes: 3 additions & 3 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,11 @@ jobs:
matrix:
os: [ubuntu-latest, macOS-latest]
steps:
- uses: actions/checkout@v2
- uses: actions/setup-go@v2
- uses: actions/checkout@v3
- uses: actions/setup-go@v3
with:
go-version: '1.17.8'
- uses: actions/cache@v2
- uses: actions/cache@v3
with:
path: ~/go/pkg/mod
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
Expand Down

0 comments on commit 01f149d

Please sign in to comment.