cleanup of build
This commit is contained in:
parent
683ee1371b
commit
762cd6b501
1 changed files with 10 additions and 9 deletions
19
Jenkins/Phabricator-windows-pipeline/Jenkinsfile
vendored
19
Jenkins/Phabricator-windows-pipeline/Jenkinsfile
vendored
|
@ -25,10 +25,9 @@ pipeline {
|
||||||
PHABRICATOR_HOST = 'https://reviews.llvm.org'
|
PHABRICATOR_HOST = 'https://reviews.llvm.org'
|
||||||
PHAB_LOG = "${WORKSPACE}/build/.phabricator-comment"
|
PHAB_LOG = "${WORKSPACE}/build/.phabricator-comment"
|
||||||
MY_BUILD_ID = "${JOB_BASE_NAME}-${BUILD_NUMBER}"
|
MY_BUILD_ID = "${JOB_BASE_NAME}-${BUILD_NUMBER}"
|
||||||
TARGET_DIR = "/mnt/nfs/results/${MY_BUILD_ID}"
|
|
||||||
RESULT_URL = "http://results.llvm-merge-guard.org/${MY_BUILD_ID}"
|
RESULT_URL = "http://results.llvm-merge-guard.org/${MY_BUILD_ID}"
|
||||||
DIFF_JSON = "${WORKSPACE}/build/diff.json"
|
|
||||||
SCRIPT_DIR = "${WORKSPACE}/llvm-premerge-checks/scripts"
|
SCRIPT_DIR = "${WORKSPACE}/llvm-premerge-checks/scripts"
|
||||||
|
// store all build results here, will be uploaded to GCS later
|
||||||
RESULT_DIR = "${WORKSPACE}\\results"
|
RESULT_DIR = "${WORKSPACE}\\results"
|
||||||
LLVM_DIR = "${WORKSPACE}\\llvm-project"
|
LLVM_DIR = "${WORKSPACE}\\llvm-project"
|
||||||
}
|
}
|
||||||
|
@ -52,7 +51,11 @@ pipeline {
|
||||||
bat 'if exist "build" rd /s/q "build"'
|
bat 'if exist "build" rd /s/q "build"'
|
||||||
git url: 'https://github.com/llvm/llvm-project.git'
|
git url: 'https://github.com/llvm/llvm-project.git'
|
||||||
}
|
}
|
||||||
powershell "New-Item -ItemType Directory -Force -Path ${RESULT_DIR}"
|
// create ${RESULT_DIR}
|
||||||
|
powershell """
|
||||||
|
Remove-Item ${RESULT_DIR} -Recurse -ErrorAction Ignore
|
||||||
|
New-Item -ItemType Directory -Force -Path ${RESULT_DIR} | Out-Null
|
||||||
|
"""
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
stage('arc patch'){
|
stage('arc patch'){
|
||||||
|
@ -97,17 +100,15 @@ pipeline {
|
||||||
Invoke-WebRequest -OutFile console-log.txt -uri "http://jenkins.local:8080/job/${JOB_BASE_NAME}/${BUILD_NUMBER}/consoleText" -ErrorAction "Continue"
|
Invoke-WebRequest -OutFile console-log.txt -uri "http://jenkins.local:8080/job/${JOB_BASE_NAME}/${BUILD_NUMBER}/consoleText" -ErrorAction "Continue"
|
||||||
|
|
||||||
Write-Host "Copying build artefacts..."
|
Write-Host "Copying build artefacts..."
|
||||||
Copy-Item "${LLVM_DIR}\\build\\CMakeCache.txt" -ErrorAction SilentlyContinue
|
Copy-Item "${LLVM_DIR}\\build\\CMakeCache.txt" -ErrorAction Continue
|
||||||
Copy-Item "${LLVM_DIR}\\build\\test-results.xml" -ErrorAction SilentlyContinue
|
Copy-Item "${LLVM_DIR}\\build\\test-results.xml" -ErrorAction Continue
|
||||||
|
|
||||||
Write-Host "Uploading results to GCS..."
|
Write-Host "Uploading results to GCS..."
|
||||||
\$ErrorActionPreference = 'SilentlyContinue'
|
\$ErrorActionPreference = 'Continue'
|
||||||
gsutil cp -Z *.* gs://llvm-premerge-checks/results/${MY_BUILD_ID}/
|
gsutil cp -Z -c *.* gs://llvm-premerge-checks/results/${MY_BUILD_ID}/
|
||||||
Write-Host "Done."
|
Write-Host "Done."
|
||||||
"""
|
"""
|
||||||
}
|
}
|
||||||
// doesn't find junit results, not sure why...
|
|
||||||
// junit "${LLVM_DIR}\\build\\test-results.xml"
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue