Skip to content

Add linters

Add linters #22

Workflow file for this run

name: 'Validate'
on:
pull_request:
branches:
- 'main'
paths:
- 'cmd/**'
- 'internal/**'
env:
MIGRATOR: 'cmd/migrator/main.go'
SERVICE: 'cmd/service/main.go'
jobs:
validate:
runs-on: ubuntu-latest
steps:
- name: 'Checkout'
uses: actions/checkout@v4
- name: 'Setup Go'
uses: actions/setup-go@v5
with:
go-version: 1.23
- name: 'Install dependencies'
run: go mod download
- name: 'Run linters'
uses: golangci/golangci-lint-action@v6
with:
version: v1.62.2
- name: 'Build migrator'
run: go build ${{ env.MIGRATOR }}
- name: 'Build service'
run: go build ${{ env.SERVICE }}
- name: 'Test'
run: go test -v ./...