name: Check .lock files
on:
    pull_request_target: null
    push:
        branches:
            - main

permissions:
    pull-requests: read

jobs:
    lockfiles:
        runs-on: ubuntu-latest
        name: Verify lock file integrity
        steps:
            - name: Prevent file change
              uses: xalvarez/prevent-file-change-action@v3
              with:
                  githubToken: ${{ secrets.GITHUB_TOKEN }}
                  pattern: .*\.lock$|^\.github\/.*$
                  trustedAuthors: kevinpapst, dependabot
