From 6fe57ae44e4ed2b70c1757c28b23ff0ca46e7099 Mon Sep 17 00:00:00 2001 From: John Bampton Date: Sun, 22 Sep 2024 09:59:43 +1000 Subject: [PATCH] Add `pre-commit` hook `shellcheck-py` to check syntax of shell scripts https://github.com/shellcheck-py/shellcheck-py https://www.shellcheck.net/ https://github.com/koalaman/shellcheck Remove bash/shell checking from the Super-Linter --- .github/workflows/super-linter.yml | 1 - .pre-commit-config.yaml | 4 ++++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/super-linter.yml b/.github/workflows/super-linter.yml index f1d359434..6a2977fbc 100644 --- a/.github/workflows/super-linter.yml +++ b/.github/workflows/super-linter.yml @@ -22,7 +22,6 @@ jobs: - name: Lint Code Base uses: super-linter/super-linter/slim@v7.1.0 env: - VALIDATE_BASH: true # VALIDATE_BASH_EXEC: true VALIDATE_DOCKERFILE_HADOLINT: true # VALIDATE_EDITORCONFIG: true diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index ef45c6a60..d93cc4ed8 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -72,6 +72,10 @@ repos: args: [--config=.github/linters/mlc_config.json, -q] types: [markdown] files: \.md$ + - repo: https://github.com/shellcheck-py/shellcheck-py + rev: v0.10.0.1 + hooks: + - id: shellcheck - repo: https://github.com/adrienverge/yamllint rev: v1.35.1 hooks: