Skip to content

chore: Add GitHub Actions workflow for creating releases #8

chore: Add GitHub Actions workflow for creating releases

chore: Add GitHub Actions workflow for creating releases #8

Workflow file for this run

on:

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

No steps defined in `steps` and no workflow called in `uses` for the following jobs: shellcheck
- push
- pull_request
# Cancels all previous workflow runs for the same branch that have not yet completed.
concurrency:
# The concurrency group contains the workflow name and the branch name.
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
# shellcheck:
# runs-on: ubuntu-latest
# steps:
# - uses: actions/checkout@v3
# - env:
# PIPELINECOMPONENTS_GLOBASSIST: true
# uses: pipeline-components/[email protected]
# with:
# directory: "**/*.sh"
# options: --format=gcc --external-sources
shellcheck:
stage: linting
image: registry.gitlab.com/pipeline-components/shellcheck:latest
script:
# anything ending on .sh, should be shell script
- |
find . -name .git -type d -prune -o -type f -name \*.sh -print0 |
xargs -0 -P $(nproc) -r -n1 shellcheck
# magic, any file with a valid shebang should be scanned aswell
- |
find . -name .git -type d -prune -o -type f -regex '.*/[^.]*$' -print0 |
xargs -0 -P $(nproc) -r -n1 sh -c 'FILE="$0"; if head -n1 "$FILE" |grep -q "^#\\! \?/.\+\(ba|d|k\)\?sh" ; then shellcheck "$FILE" ; else /bin/true ; fi '