name: golangci-lint

on:
  push:
    branches:
      - develop
  pull_request:
    types: [opened, reopened, synchronize]

jobs:
  golangci:
    name: lint
    runs-on: ubuntu-latest
    steps:
      - name: Install Go
        uses: actions/setup-go@v3
        with:
          go-version: "1.20.7"
      - uses: actions/checkout@v2
        with:
          fetch-depth: '0'
      - name: golangci-lint
        uses: golangci/golangci-lint-action@v3.4.0
        with:
          version: v1.52.2
          args: -v
