Squashed 'autobuild/Common_scripts/' changes from b68995a..44b189c

44b189c Add filtered copy
0285f04 Up the timeout protecting eclipse project opening
707f63a Merge commit '38db763aa82610cf5e09198bd6427a29bd8923ce'
d48825b Use non-deprecated API
d8b38d9 Make release script use new API
09154e9 Make release script use new API
d7e2e11 Autobuilderscript definition is needed later
b94b0cb Remove redundant parameter

git-subtree-dir: autobuild/Common_scripts
git-subtree-split: 44b189c724
This commit is contained in:
Dan Hawkins 2020-02-25 08:22:11 +00:00
commit 1fd014bc55
4 changed files with 73 additions and 4 deletions

View file

@ -227,7 +227,7 @@ def doBuild(apps, ds5folder, toolchainfolder, ds5shellcommand, buildcommand, sou
// The lock is being used because it was being found that the doKillLeftovers was affecting other builds
lock(resource: "eclipsebuild_${env.NODE_NAME}") {
try {
timeout(time: 2, unit: 'MINUTES') {
timeout(time: 5, unit: 'MINUTES') {
addToolchainPath(toolchainfolder)
doImportProjects(ds5folder, toolchainfolder, ds5shellcommand, buildcommand, sourcefolder)
}

70
copy/filtered.groovy Normal file
View file

@ -0,0 +1,70 @@
pipeline {
agent { label AGENT_LABEL }
stages {
stage('Initial setup') {
steps {
script {
meta = load("${WORKSPACE}/autobuild/Common_scripts/autobuilder.groovy").startnonbuild(this)
importer = load("${autobuilder.commonscripts()}/import/importer.groovy")
}
}
}
stage('Clean') {
steps {
script {
env.IMPORT = "${WORKSPACE}/import"
env.FILTEREDDEST = "${WORKSPACE}/filtered"
cleanfolders = [
FILTEREDDEST,
IMPORT,
]
cleaner = load("${autobuilder.commonscripts()}/clean/clean.groovy")
cleaner.clean(cleanfolders)
}
}
}
stage('Import artifacts') {
steps {
script {
importer.artifactimport(meta, ARTIFACT_LOCATION, ARTIFACT_PROJECT, ARTIFACT_BUILD_SELECTOR, RELEASE_REPO, RELEASE_REVISION, IMPORT)
}
}
}
stage('Filtered copy') {
steps {
script {
dir(IMPORT) {
fileOperations([
fileCopyOperation(excludes: EXCLUDES,
flattenFiles: FLATTENOUTPUT,
includes: INCLUDES,
targetLocation: FILTEREDDEST)])
}
}
}
}
stage('Archiving artifacts') {
steps {
script {
def artifactlist = meta.generateartifacts(["filtered/**"])
archiveArtifacts "${artifactlist}"
}
}
}
}
post {
always {
echo 'Post-build'
}
failure {
echo 'Failed build'
}
unstable {
echo 'Unstable build'
}
success {
echo 'Succeeded build'
}
}
}

View file

@ -5,7 +5,7 @@ pipeline {
steps {
script {
autobuilderscript = load("${WORKSPACE}/autobuild/Common_scripts/autobuilder.groovy")
meta = autobuilderscript.start(this, PRODUCT_NAME, SUBCOMPONENT_NAME, JIRA_KEY, RELEASE_REPO)
meta = autobuilderscript.startbuild(this, PRODUCT_NAME, SUBCOMPONENT_NAME, RELEASE_REPO)
}
}
}

View file

@ -5,7 +5,7 @@ pipeline {
steps {
script {
autobuilderscript = load("${WORKSPACE}/autobuild/Common_scripts/autobuilder.groovy")
meta = autobuilderscript.start(this, PRODUCT_NAME, SUBCOMPONENT_NAME, JIRA_KEY, RELEASE_REPO)
meta = autobuilderscript.startbuild(this, PRODUCT_NAME, SUBCOMPONENT_NAME, RELEASE_REPO)
}
}
}
@ -86,4 +86,3 @@ pipeline {
}
}
}