| # Fails when .github/workflows/actions.lock is out of sync with the | |
| # workflows or a locked pin no longer verifies upstream. | |
| name: verify-lockfile | |
| on: | |
| pull_request: | |
| push: | |
| branches: ["main"] | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} | |
| cancel-in-progress: true | |
| permissions: | |
| contents: read | |
| jobs: | |
| verify: | |
| name: Verify actions lockfile | |
| runs-on: ubuntu-slim | |
| env: | |
| GH_TOKEN: ${{ github.token }} | |
| steps: | |
| - uses: actions/checkout@v7.0.1 | |
| with: | |
| persist-credentials: false | |
| - run: gh extension install github/gh-actions-lock | |
| - run: gh actions-lock --verify |