BUILD_USER with Active Choices

11 views
Skip to first unread message

Ivan Kabaivanov

unread,
Sep 19, 2018, 1:18:54 AM9/19/18
to Jenkins Users
Hi, Jenkins users.

I am not 100% sure if this is the correct list, but I want to pass ${BUILD_USER} to Active Choices.  Something like:

if (BUILD_USER.equals("user")) {

  return ["Option1"]

} else {

  return ["Option2"]

}

I don't seem to be able to do it.  It looks like all the parameters steps are doing in parallel so when the Active Choice Groovy scripts are evaluated, BUILD_USER is not defined.

Thanks,
IvanK.
Reply all
Reply to author
Forward
0 new messages