Re: Getting cause for branch indexing in multibranch pipeline

2018-08-23 Thread Ramanathan Muthaiah
Thanks Sverre Moe, you made my day ! Here is the final version of the code snippet. > import jenkins.branch.BranchIndexingCause > > final def jenkinsInstance = jenkins.model.Jenkins.getInstance() > final def jenkinsProject = jenkinsInstance.getItemByFullName( > jenkinsProjectName) >

Re: Getting cause for branch indexing in multibranch pipeline

2018-08-22 Thread Sverre Moe
import jenkins.branch.BranchIndexingCause final def jenkinsInstance = jenkins.model.Jenkins.getInstance() final def jenkinsProject = jenkinsInstance.getItemByFullName( jenkinsProjectName) if (jenkinsProject != null) { final def job = jenkinsProject.getAllJobs().first()