change WORKSPACE var sintax

This commit is contained in:
Roberto Cirillo 2022-09-28 12:48:41 +02:00
parent 6040738a12
commit 9fa9903bf4
1 changed files with 3 additions and 3 deletions

6
Jenkinsfile vendored
View File

@ -85,7 +85,7 @@ pipeline {
date=`date`; date=`date`;
mkdir -p ${DEPLOY_FILE_ROOT_FOLDER} mkdir -p ${DEPLOY_FILE_ROOT_FOLDER}
mkdir -p "${WORKSPACE}/CD" mkdir -p "${WORKSPACE}/CD"
mv -v ${DEPLOY_FILE_ROOT_FOLDER} ${env.WORKSPACE}/CD mv -v "${DEPLOY_FILE_ROOT_FOLDER}" "${WORKSPACE}/CD"
''' '''
} }
} }
@ -103,7 +103,7 @@ pipeline {
// parse the report and extract the data // parse the report and extract the data
// def components = getComponentsFromCSV(deployList) // def components = getComponentsFromCSV(deployList)
println "Going to check the deploy file in ${DEPLOY_FILE_ROOT_FOLDER}" println "Going to check the deploy file in ${DEPLOY_FILE_ROOT_FOLDER}"
def components =getComponentsFromCSVDir3(${DEPLOY_FILE_ROOT_FOLDER}) def components =getComponentsFromCSVDir3("${WORKSPACE}/CD")
if (components.size() > 0) { if (components.size() > 0) {
def componentSet=components.toSet(); def componentSet=components.toSet();
for (component in componentSet) { for (component in componentSet) {
@ -365,7 +365,7 @@ def getComponentsFromCSVDir2(def dirPath){
@NonCPS @NonCPS
def getComponentsFromCSVDir3(def dirPath){ def getComponentsFromCSVDir3(def dirPath){
println "checking current folder" println "checking current folder"
dh = new File(${env.WORKSPACE}+"/CD") dh = new File(dirPath)
println "current folder path: "+dh.path println "current folder path: "+dh.path
// dh.eachFileRecurse { // dh.eachFileRecurse {
// println it // println it