Commit 3158d01e authored by Andrew Nicols's avatar Andrew Nicols

runTaks: Define runner

parent 3cf3d148
......@@ -74,18 +74,18 @@ class Task {
return pathToRunner
} else if (moodleVersion) {
runner = "${script.env.HOME}/scripts/runner/${moodleVersion.name}/run.sh"
def runner = "${script.env.HOME}/scripts/runner/${moodleVersion.name}/run.sh"
if (!fileExists(runner)) {
runner = "${script.env.HOME}/scripts/runner/master/run.sh"
}
return runner
} else {
versionName = sh (
def versionName = sh (
script: 'grep "\\$branch" moodle/version.php | sed "s/^[^\']*\'\\([^\']*\\).*\$/\\1/"',
returnStdout: true
).trim()
runner = "${script.env.HOME}/scripts/runner/${versionName}/run.sh"
def runner = "${script.env.HOME}/scripts/runner/${versionName}/run.sh"
if (!fileExists(runner)) {
runner = "${script.env.HOME}/scripts/runner/master/run.sh"
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment