Skip to content

ci: run go vet and staticcheck separately #40

ci: run go vet and staticcheck separately

ci: run go vet and staticcheck separately #40

Workflow file for this run

name: PR
on:
pull_request:
types: [opened, reopened, synchronize]
jobs:
lint:
name: golangci-lint
runs-on: ubuntu-latest
steps:
- name: checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 1
- name: set up go
uses: WillAbides/setup-go-faster@v1
with:
go-version-file: go.mod
- name: lint
uses: golangci/golangci-lint-action@v6
with:
version: latest
check:
name: go vet and staticcheck
runs-on: ubuntu-latest
steps:
- name: checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 1
- name: set up go
uses: WillAbides/setup-go-faster@v1
with:
go-version-file: go.mod
- name: run go vet
run: go vet ./...
- name: run staticcheck
uses: dominikh/staticcheck-action@v1
with:
version: latest
tests:
name: unit tests with race detector enabled
runs-on: ubuntu-latest
steps:
- name: checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 1
- name: set up go
uses: WillAbides/setup-go-faster@v1
with:
go-version-file: go.mod
- name: run unit tests
run: go test -v -race ./...