The "Check SPDX headers" step only read line 1 of each workflow. Dependabot's
actions-lock bumps now prepend "# This workflow is managed by gh
actions-lock." above the existing header, so every workflow's SPDX line sits
on line 2 or later and lint-workflows fails on main ("missing SPDX header",
one error per file). Moving the SPDX line back to the top would last only
until the next Dependabot bump.
The check now accepts an SPDX-License-Identifier anywhere in the leading
block of comment and blank lines, before the first YAML line. A file whose
only SPDX line comes after YAML content, or that has none, still fails.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0132Cdz3iwk2QGKv2sUhhsye
What was wrong
lint-workflowsfails onmainwithERROR: .github/workflows/<file>.yml missing SPDX headerfor all 20 workflows (exit code 20). The SPDX check reads only line 1. Dependabot's actions-lock bumps (from #136 on) prepend# This workflow is managed by gh actions-lock.above the existing header, so every SPDX line is now on line 2 or later. Moving it back to the top would only last until the next bump.Change
workflow-linter.yml: the "Check SPDX headers" step now accepts anSPDX-License-Identifieranywhere in the leading block of comment and blank lines, before the first YAML line. A file whose only SPDX line comes after YAML, or that has none, still fails.Testing
I ran the step scripts locally against this branch:
name:both fail; a file with SPDX after a blank line and another comment passes.Generated by Claude Code