Print out items in sparse item list if the list is not empty
This commit is contained in:
parent
5be5dfce45
commit
ddc231ccac
1 changed files with 3 additions and 3 deletions
|
|
@ -11,12 +11,12 @@ String getGitInfo(String workingSetRootPath) {
|
|||
}
|
||||
|
||||
@NonCPS
|
||||
def SparseCheckoutPaths sparsecheckoutconfig(ArrayList<String> paths) {
|
||||
def ArrayList<SparseCheckoutPath> sparsecheckoutconfig(ArrayList<String> paths) {
|
||||
ArrayList<SparseCheckoutPath> sparsecheckoutpaths = new ArrayList<SparseCheckoutPath>()
|
||||
for (path in paths) {
|
||||
sparsecheckoutpaths.add(new SparseCheckoutPath(path))
|
||||
}
|
||||
return new SparseCheckoutPaths(sparsecheckoutpaths)
|
||||
return sparsecheckoutpaths
|
||||
}
|
||||
|
||||
def String uniquereporootname(String gitURL) {
|
||||
|
|
@ -115,7 +115,7 @@ def gitCheckout(String gitURL, String revision, String targetDir, String repoRoo
|
|||
[$class: 'CloneOption', depth: cloneDepth, noTags: false, reference: reporootpath, shallow: shallowClone, timeout: 120],
|
||||
[$class: 'CheckoutOption', timeout: 120],
|
||||
[$class: 'RelativeTargetDirectory', relativeTargetDir: targetDir],
|
||||
[$class: 'SparseCheckoutPaths', sparsecheckoutconfig(sparseitemlist)],
|
||||
[$class: 'SparseCheckoutPaths', sparseCheckoutPaths: sparsecheckoutconfig(sparseitemlist)],
|
||||
],
|
||||
submoduleCfg: [],
|
||||
])
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue