diff --git a/.github/workflows/workflow-linter.yml b/.github/workflows/workflow-linter.yml index 7106aa6..ba92b1c 100644 --- a/.github/workflows/workflow-linter.yml +++ b/.github/workflows/workflow-linter.yml @@ -44,7 +44,7 @@ jobs: [ -f "$file" ] || continue # actions-lock may prepend its own comment. Require the licence # in the leading comment block, before the workflow body. - if ! awk '/^# SPDX-License-Identifier:/ { found=1 } /^[^#[:space:]]/ { exit } END { exit !found }' "$file"; then + if ! awk '/^# SPDX-License-Identifier:/ { found=1 } /^[[:space:]]*[^#[:space:]]/ { exit } END { exit !found }' "$file"; then echo "ERROR: $file missing SPDX header" failed=1 fi