chore: bump workflows

main
sudo pacman -Syu 2024-08-22 15:09:16 +07:00
parent b1d005e311
commit 418d1baaee
1 changed files with 23 additions and 17 deletions

View File

@ -4,21 +4,31 @@ on:
push:
branches:
- main
paths:
- "**.go"
- "go.mod"
- "go.sum"
pull_request:
branches:
- main
paths:
- "**.go"
- "go.mod"
- "go.sum"
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
test:
name: Test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-go@v3
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: "1.19"
check-latest: true
cache: true
go-version: "stable"
- run: go test -race -failfast ./...
build:
name: Build
@ -27,25 +37,21 @@ jobs:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-go@v3
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: "1.19"
check-latest: true
cache: true
- run: go build
go-version: "stable"
- run: go build ./cmd/gofimports
golangci-lint:
name: golangci-lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: actions/setup-go@v3
- uses: actions/setup-go@v5
with:
go-version: "1.19"
check-latest: true
cache: true
- uses: golangci/golangci-lint-action@v3
go-version: "stable"
- uses: golangci/golangci-lint-action@v6
with:
version: latest