name: golangci-lint

on:
  pull_request:
    types: [opened, edited, synchronize, reopened]

# Remove all permissions from GITHUB_TOKEN except metadata.
permissions: {}

jobs:
  golangci:
    name: lint
    runs-on: ubuntu-latest
    strategy:
      matrix:
        working-directory:
          - ""
          - test
    steps:
      - uses: actions/checkout@v4
      - uses: actions/setup-go@v5
        with:
          go-version: 1.19
      - name: golangci-lint
        uses: golangci/golangci-lint-action@v6.0.1
        with:
          version: v1.50.1
          working-directory: ${{matrix.working-directory}}
