From bdd1c7bcb5fa8d73a56cc24fa5bb0515e03c4d06 Mon Sep 17 00:00:00 2001 From: Bas Date: Tue, 7 Feb 2023 04:08:57 +0100 Subject: [PATCH] Catch ShellCheck errors in pre-commit using same command as CI. (#9752) --- .pre-commit-config.yaml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 3f4f0918c..b2d778634 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -28,6 +28,14 @@ repos: args: [ -r, "~MD013,~MD029" ] exclude: "^.git" + - repo: https://github.com/jumanjihouse/pre-commit-hooks + rev: 3.0.0 + hooks: + - id: shellcheck + args: [ --severity, "error" ] + exclude: "^.git" + files: "\\.sh$" + - repo: local hooks: - id: ansible-lint