name: SwiftLint

on:
  push:
    paths:
      - '.gitea/workflows/swiftlint.yml'
      - '.swiftlint.yml'
      - '**/*.swift'
  pull_request:
    paths:
      - '.gitea/workflows/swiftlint.yml'
      - '.swiftlint.yml'
      - '**/*.swift'
  workflow_dispatch:
    paths:
      - '.gitea/workflows/swiftlint.yml'
      - '.swiftlint.yml'
      - '**/*.swift'

jobs:
  SwiftLint:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - name: SwiftLint
        uses: norio-nomura/action-swiftlint@3.2.1
        with:
          args: --strict
        env:
          WORKING_DIRECTORY: Source
