ci: Add a commit validation entrypoint

This commit is contained in:
Colin Walters 2021-02-03 00:42:05 +00:00 committed by OpenShift Merge Robot
parent 4dd80a8b9c
commit 9b2e78ed05
2 changed files with 8 additions and 4 deletions

View File

@ -30,11 +30,9 @@ codestyle: {
cosaPod(buildroot: true) {
checkout scm
shwrap("""
# Jenkins by default only fetches the branch it's testing. Explicitly fetch master
# for ci-commitmessage-submodules.sh
# Ensures that we get refs to aid `git describe`
git fetch origin +refs/heads/master:refs/remotes/origin/master
ci/ci-commitmessage-submodules.sh
ci/codestyle.sh
ci/commit-validation.sh
""")
}
},

6
ci/commit-validation.sh Executable file
View File

@ -0,0 +1,6 @@
#!/bin/bash
set -xeuo pipefail
# Add cheap (non-building) checks here
dn=$(dirname $0)
${dn}/codestyle.sh
${dn}/ci-commitmessage-submodules.sh