Merge commit '447b5234db39500e985b7900bc2264319f4b5ae3' into master
This commit is contained in:
commit
51156e2121
1 changed files with 21 additions and 0 deletions
|
|
@ -341,4 +341,25 @@ def artifactimport(meta,
|
|||
return artifactimport(meta, importoptions, destpath)
|
||||
}
|
||||
|
||||
// Import the artifacts of a named child component found below parent meta's hierarchy
|
||||
def artifactimport(meta, parentmeta, String childproduct, String childsubcomponent, importoptions, String destinationfolder) {
|
||||
// Import from parent meta
|
||||
def childmeta = meta.getNewMetaObject()
|
||||
def childmeta2
|
||||
echo "Finding meta associated with child: Product: ${childproduct} Sub-component: ${childsubcomponent}"
|
||||
def findresults = parentmeta.findAssociatedMeta(childproduct, childsubcomponent)
|
||||
if (findresults.matchfound) {
|
||||
childmeta = findresults.matchedmeta
|
||||
if (childmeta.releaseinfo.released) {
|
||||
importoptions.releaserepo(childmeta.releaseinfo.releaserepoURL, childmeta.releasetag())
|
||||
} else {
|
||||
importoptions.jenkinsjob(childmeta.jenkinsbuildinfo.buildjobname, childmeta.jenkinsbuildinfo.buildnumber)
|
||||
}
|
||||
childmeta2 = importer.artifactimport(meta, importoptions, destinationfolder)
|
||||
} else {
|
||||
error("Could not find meta associated with child: Product: ${childproduct} Sub-component: ${childsubcomponent}")
|
||||
}
|
||||
return childmeta2
|
||||
}
|
||||
|
||||
return this;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue