From 8ba0aa01376b7c53480966f0d45bc5d3bb653459 Mon Sep 17 00:00:00 2001 From: Vasilis Tsiligiannis Date: Wed, 6 Jul 2022 21:31:16 +0300 Subject: [PATCH] gitlab-ci: Introduce sign-off check Signed-off-by: Vasilis Tsiligiannis --- .gitlab-ci.yml | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 .gitlab-ci.yml diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml new file mode 100644 index 0000000..e116dc7 --- /dev/null +++ b/.gitlab-ci.yml @@ -0,0 +1,18 @@ +variables: + GITLAB_CI_IMAGE_ALPINE: 'alpine:3.16.0' +stages: + - static + +# 'static' stage +sign_off: + stage: static + needs: [] + image: ${GITLAB_CI_IMAGE_ALPINE} + before_script: + - apk add --no-cache git + script: >- + git log + --grep "^Signed-off-by: .\+<.\+\(@\| at \).\+\(\.\| dot \).\+>$" + --invert-grep + --format="Detected commit '%h' with missing or bad sign-off! Please read 'CONTRIBUTING.md'." + --exit-code