summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatric Stout <TrueBrain@users.noreply.github.com>2018-04-08 17:39:45 +0200
committerGitHub <noreply@github.com>2018-04-08 17:39:45 +0200
commit97c0594cedcad866bbdea8a0f86406b5c38694a3 (patch)
tree9167ccdd58ef5e8b0dbc2205de9db3a7d9b579b4
parent19076c24c1f3baf2a22d1fa832d5688216cf54a3 (diff)
downloadopenttd-97c0594cedcad866bbdea8a0f86406b5c38694a3.tar.xz
Add: run Clang 3.8 and commit-checker during CI (#6694)
-rw-r--r--Jenkinsfile29
1 files changed, 23 insertions, 6 deletions
diff --git a/Jenkinsfile b/Jenkinsfile
index 23802f5f1..dcba7ff70 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -1,8 +1,16 @@
-def ci_targets = [
- ["linux-amd64", "openttd/compile-farm-ci:linux-amd64"],
- ["linux-i386", "openttd/compile-farm-ci:linux-i386"],
+def ci_checkers_targets = [
+ ["commit-checker", "openttd/compile-farm-ci:commit-checker"],
]
-def ci_stages = ci_targets.collectEntries {
+def ci_builds_targets = [
+ ["linux-amd64-clang-3.8", "openttd/compile-farm-ci:linux-amd64-clang-3.8"],
+ ["linux-amd64-gcc-6", "openttd/compile-farm-ci:linux-amd64-gcc-6"],
+ ["linux-i386-gcc-6", "openttd/compile-farm-ci:linux-i386-gcc-6"],
+]
+
+def ci_checkers_stages = ci_checkers_targets.collectEntries {
+ ["${it[0]}" : generateCI(it[0], it[1])]
+}
+def ci_builds_stages = ci_builds_targets.collectEntries {
["${it[0]}" : generateCI(it[0], it[1])]
}
@@ -10,6 +18,7 @@ def generateCI(display_name, image_name) {
return {
dir("${display_name}") {
unstash "source"
+
docker.image("${image_name}").withRun("--volumes-from ${hostname} --workdir " + pwd()) { c->
sh "docker logs --follow ${c.id}"
sh "exit `docker wait ${c.id}`"
@@ -21,11 +30,19 @@ def generateCI(display_name, image_name) {
node {
stage("Checkout") {
checkout scm
+
+ // Ensure we also have origin/master available
+ sh "git fetch --no-tags origin master:refs/remotes/origin/master"
+
stash name: "source", useDefaultExcludes: false
}
- stage("CI") {
- parallel ci_stages
+ stage("Checkers") {
+ parallel ci_checkers_stages
+ }
+
+ stage("Builds") {
+ parallel ci_builds_stages
}
}