Skip to content

shellcheck.yml

shellcheck.yml #33

Workflow file for this run

name: ShellCheck

Check failure on line 1 in .github/workflows/shellcheck.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/shellcheck.yml

Invalid workflow file

(Line: 20, Col: 9): There's not enough info to determine what you meant. Add one of these properties: run, shell, uses, with, working-directory, (Line: 21, Col: 8): Unexpected value 'shopt -s globstar nullglob files=(**/*.sh) if (( ${#files[@]} == 0 )); then echo "No shell scripts found." exit 0 fi shellcheck -x "${files[@]}"'
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
shellcheck:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Install ShellCheck
run: |
sudo apt-get update
sudo apt-get install -y shellcheck
- name: Run ShellCheck
run: |
shopt -s globstar nullglob
files=(**/*.sh)
if (( ${#files[@]} == 0 )); then
echo "No shell scripts found."
exit 0
fi
shellcheck -x "${files[@]}"