Fix golangci-lint by adding go mod tidy and specifying paths ./... for linting

This commit is contained in:
Damir Mukimov 2025-11-27 04:30:36 +01:00
parent 39fae4dbf8
commit afaf952a1a
No known key found for this signature in database
GPG Key ID: 42996CC7C73BC750
2 changed files with 13 additions and 4 deletions

View File

@ -55,11 +55,17 @@ jobs:
go-version: "1.25"
cache: true
- name: Install dependencies
run: go mod download
- name: Tidy modules
run: go mod tidy
- name: golangci-lint
uses: golangci/golangci-lint-action@v6
with:
version: latest
args: --timeout=5m
args: --timeout=5m ./...
# Testing and coverage (runs on PRs and pushes)
test:

View File

@ -2,9 +2,9 @@ name: CI
on:
push:
branches: [master]
branches: [main]
pull_request:
branches: [master]
branches: [main]
jobs:
lint-and-test:
@ -25,11 +25,14 @@ jobs:
- name: Install dependencies
run: go mod download
- name: Tidy modules
run: go mod tidy
- name: Lint
uses: golangci/golangci-lint-action@v6
with:
version: latest
args: --timeout=5m
args: --timeout=5m ./...
- name: Test
run: go test -v -race -coverprofile=coverage.out ./...