name: Code analysis

on: [pull_request]

jobs:
  golangci-lint:
    runs-on: ubuntu-latest
    steps:
      - name: Check out code into the Go module directory
        uses: actions/checkout@v3
        with:
          fetch-depth: 0
      - name: Linting with golangci-lint
        uses: reviewdog/action-golangci-lint@v2
        with:
          github_token: ${{ secrets.ACCESS_TOKEN }}
          reporter: github-pr-review
