how to return a failure from scriptler ?

19 views
Skip to first unread message

Guy Matz

unread,
Jul 13, 2017, 11:07:08 AM7/13/17
to jenkins...@googlegroups.com
Hello!
I'm trying to have a build fail when something goes wrong in scriptler, but I can't get this to work.  I'm trying something like this:
doSomething() || return false

This fails in scripler with:
Execution of script [promoteBuild.groovy] failed - org.codehaus.groovy.control.MultipleCompilationErrorsException: startup failed:
Script1.groovy: 51: unexpected token: return @ line 51, column 85.
   doSomething() || return fal

Anyone know how to fail a build from scriptler?

Thanks!
Guy

Guy Matz

unread,
Jul 16, 2017, 11:46:55 AM7/16/17
to jenkins...@googlegroups.com
So I think a false return from scriptler is supposed to fail the build.  anyone know why this syntax does not work in scriptler  Better yet, does anyone know what doe work?

Thanks!
Reply all
Reply to author
Forward
0 new messages