GHA/checksrc: add actionlint, fix or silence issues found

It also does shellcheck on `run:` elements, overlapping with
the homegrown `shellcheck-ci.sh` with the same purpose. But it also does
more and perhaps could replace the script too, especially in curl
sub-repos.

Also:
- GHA/macos: delete potentially useful, but commented, and ultimately
  unused, non-default Xcode-testing logic. It's causing unused matrix
  exceptions, upsetting actionlint.

Ref: https://github.com/rhysd/actionlint

Closes #19373
This commit is contained in:
Viktor Szakats 2025-11-05 02:50:42 +01:00
parent 403a2c2b06
commit 60dd72b1be
No known key found for this signature in database
GPG key ID: B5ABD165E2AEF201
4 changed files with 13 additions and 32 deletions

View file

@ -124,7 +124,7 @@ jobs:
timeout-minutes: 5
steps:
- name: 'install prereqs'
run: HOMEBREW_NO_AUTO_UPDATE=1 /home/linuxbrew/.linuxbrew/bin/brew install shellcheck zizmor
run: HOMEBREW_NO_AUTO_UPDATE=1 /home/linuxbrew/.linuxbrew/bin/brew install actionlint shellcheck zizmor
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
@ -137,6 +137,13 @@ jobs:
eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)"
zizmor --pedantic .github/workflows/*.yml .github/dependabot.yml
- name: 'actionlint'
run: |
eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)"
export SHELLCHECK_OPTS='--exclude=1090,1091,2086,2153 --enable=avoid-nullary-conditions,deprecate-which'
actionlint --version
actionlint --ignore matrix .github/workflows/*.yml
- name: 'shellcheck CI'
run: |
eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)"