migrate golangci-lint config to version 2

update golangci workflow
This commit is contained in:
2026-02-15 15:31:20 +00:00
parent 98d7618cdd
commit 736d940d4e
2 changed files with 140 additions and 49 deletions

View File

@@ -1,12 +1,14 @@
name: CI
on:
workflow_dispatch:
push:
branches: [ "main" ]
branches: ['main']
paths:
- '**.go'
pull_request:
branches: [ "main" ]
branches: ['main']
paths:
- '**.go'
jobs:
@@ -23,7 +25,8 @@ jobs:
uses: actions/setup-go@v5
with:
go-version: '1.24'
- name: Install golangci-lint
run: go install github.com/golangci/golangci-lint/cmd/golangci-lint@latest
- name: Run golangci-lint
run: golangci-lint run ./...
- name: golangci-lint
uses: golangci/golangci-lint-action@v9
with:
version: v2.6.0
args: --config .golangci.yml