name: Run lint

on: [ push, pull_request ]

permissions:
  contents: read

jobs:
  lint:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout code
        uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
      - name: Update Go
        uses: actions/setup-go@v5.0.1
        with:
          go-version: '>=1.21.0'
          cache: false
      - name: Lint
        uses: golangci/golangci-lint-action@a4f60bb28d35aeee14e6880718e0c85ff1882e64 # v6.0.1
        with:
          # version of golangci-lint to use in form of v1.2 or v1.2.3 or `latest` to use the latest version
          version: latest

          # Optional: show only new issues if it's a pull request. The default value is `false`.
          # only-new-issues: true

          # Read args from .golangci.yaml
          # args:
