How to get seed job name inside Jenksin Job DSL script?

I am using a Freestyle project / work with the build step Process Job DSLsprovided by the Jenkins Job DSL plugin , that is, is a "seed" work. How can I, from the code provided Use the provided DSL script, get the name of the seed job?

I tried to apply the answers to this question , but none of them worked.

+4
source share
1 answer

All string variables are entered in DSL scripts; see Accessing Jenkins Environment Variables. The variable JOB_NAMEcontains the name of the initial job.

println JOB_NAME
+6
source

Source: https://habr.com/ru/post/1607681/


All Articles