name: Shell Code Quality on: pull_request: paths: - '.docker/**.sh' - 'lib/dojo-src/rebuild-dojo.sh' - 'utils/**.sh' # Allow manual triggering workflow_dispatch: # Allow other workflows (e.g. Publish) to invoke this one. workflow_call: env: fail-fast: true permissions: contents: read jobs: shellcheck: name: ShellCheck runs-on: ubuntu-latest steps: - name: Check out code uses: actions/checkout@v6 - name: Run ShellCheck run: | docker run --rm koalaman/shellcheck:stable --version # Scripts ran in the container (Alpine uses BusyBox to provide the ash shell [with bash compatibility enabled]) find .docker -type f -name '*.sh' -exec \ docker run --rm -v "$PWD:/mnt" -w /mnt koalaman/shellcheck:stable --severity=warning --shell=busybox {} + # Project utility scripts (use of bash or compatible assumed) find lib/dojo-src utils -type f -name '*.sh' -exec \ docker run --rm -v "$PWD:/mnt" -w /mnt koalaman/shellcheck:stable --severity=warning --shell=bash {} +