16 - how to stop build execution

This commit is contained in:
Juraj Michalek
2014-05-13 10:48:36 +02:00
parent fe7b073aa8
commit 0e30e1333d
2 changed files with 23 additions and 0 deletions

View File

@@ -0,0 +1,15 @@
task workingTask {
description 'Task that works'
doLast {
println 'Everything is ok'
}
}
task failingTask {
description 'Task that fails'
doLast {
throw new GradleException("Problem detected. Build failed")
}
}