name: golangci-lint
on:
  push:
    tags:
      - v*
    branches:
      - master
      - main
  pull_request:
    paths-ignore:
      - '*.md'
permissions:
  contents: read
  pull-requests: read
jobs:
  golangci:
    name: Run golangci-lint
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v3
      - uses: actions/setup-go@v3
        with:
          go-version-file: go.mod
          cache: true
          cache-dependency-path: go.sum
      - name: golangci-lint
        uses: golangci/golangci-lint-action@v3.2.0
        with:
          args: --timeout 3m --verbose
