gitlab-ci: Introduce sign-off check

Signed-off-by: Vasilis Tsiligiannis <acinonyx@openwrt.gr>
master
Vasilis Tsiligiannis 2022-07-06 21:31:16 +03:00
parent 7dd800fd65
commit 8ba0aa0137
1 changed files with 18 additions and 0 deletions

18
.gitlab-ci.yml 100644
View File

@ -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