From faa3b8463413bc84d3161ac7f88ab8a17c2d226f Mon Sep 17 00:00:00 2001 From: Andrei Dumitrescu <5057797+andreidmt@users.noreply.github.com> Date: Mon, 6 Feb 2023 16:32:31 +0100 Subject: [PATCH] ci: update githooks to disable commiting if in CI --- .githooks/commit-msg | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.githooks/commit-msg b/.githooks/commit-msg index 762d327..947d73f 100755 --- a/.githooks/commit-msg +++ b/.githooks/commit-msg @@ -1,5 +1,10 @@ #!/bin/sh -e +# Skip in CI +if [ -n "$CI" ]; then + exit 0 +fi + # Remove comments from commit message to not trigger [body-max-line-length] message=$(sed '/^#/d' < "$1")