-
Type:
New Feature
-
Resolution: Fixed
-
Priority:
Major
-
Component/s: groovy-label-assignment-plugin
-
None
quoted from https://github.com/jenkinsci/groovy-label-assignment-plugin/pull/1:
in your groovy script, you can reference the current Jenkins job as âcurrentJobâ and do stuff like that:
[âwindowsâ, âlinuxâ, âmacâ].find { currentJob.name.toLowerCase().contains(it) }The piece of code above would automatically assign the label according to the job name.