23 lines
841 B
Groovy
23 lines
841 B
Groovy
|
|
// Take a list of Sub-job descriptors and output folder pairs, copy the artifacts, while filling in a string of artifact folders
|
|
def combineSubjobArtifacts(meta, subJobs) {
|
|
def importer = load("${autobuilder.commonscripts()}/import/importer.groovy")
|
|
|
|
def ArrayList<String> artifactFolders = new ArrayList<String>()
|
|
for (subJob in subJobs) {
|
|
def subJobObject = subJob[0]
|
|
if (subJobObject != null) {
|
|
def subJobName = subJobObject.getProjectName()
|
|
def subJobNumber = subJobObject.getNumber()
|
|
destFolder = subJob[1]
|
|
dir(destFolder) {
|
|
deleteDir()
|
|
}
|
|
importer.artifactimport(meta, subJobName, subJobNumber, destFolder)
|
|
artifactFolders.add("${destFolder}/**")
|
|
}
|
|
}
|
|
return artifactFolders;
|
|
}
|
|
|
|
return this;
|