Add gitParameter
This commit is contained in:
parent
c2af9305f2
commit
b6d4f27dd5
@ -3,6 +3,7 @@ pipeline {
|
|||||||
dockerfile true
|
dockerfile true
|
||||||
}
|
}
|
||||||
parameters {
|
parameters {
|
||||||
|
gitParameter branchFilter: 'origin/(.*)', defaultValue: 'training_and_evaluation', name: 'BRANCH', type: 'PT_BRANCH'
|
||||||
buildSelector(
|
buildSelector(
|
||||||
defaultSelector: lastSuccessful(),
|
defaultSelector: lastSuccessful(),
|
||||||
description: 'Which build to use for copying artifacts',
|
description: 'Which build to use for copying artifacts',
|
||||||
@ -10,15 +11,11 @@ pipeline {
|
|||||||
)
|
)
|
||||||
}
|
}
|
||||||
stages {
|
stages {
|
||||||
stage('Check out from version control') {
|
stage('Stage 1') {
|
||||||
steps {
|
|
||||||
checkout([$class: 'GitSCM', branches: [[name: '*/training_and_evaluation']], extensions: [], userRemoteConfigs: [[credentialsId: 's444421', url: 'https://git.wmi.amu.edu.pl/s444421/ium_444421.git']]])
|
|
||||||
}
|
|
||||||
}
|
|
||||||
stage('Script') {
|
|
||||||
steps {
|
steps {
|
||||||
|
git branch: "${params.BRANCH}", url: 'https://git.wmi.amu.edu.pl/s444421/ium_444421.git'
|
||||||
copyArtifacts filter: '*', projectName:'s444421-create-dataset', selector: buildParameter('BUILD_SELECTOR')
|
copyArtifacts filter: '*', projectName:'s444421-create-dataset', selector: buildParameter('BUILD_SELECTOR')
|
||||||
copyArtifacts filter: '*', projectName:'s444421-training/training_and_evaluation', selector: buildParameter('BUILD_SELECTOR')
|
copyArtifacts filter: '*', projectName:'s444421-training/${BRANCH}', selector: buildParameter('BUILD_SELECTOR')
|
||||||
copyArtifacts filter: '*', projectName:'s444421-evaluation/training_and_evaluation', optional: true
|
copyArtifacts filter: '*', projectName:'s444421-evaluation/training_and_evaluation', optional: true
|
||||||
sh 'ipython ./evaluation.py'
|
sh 'ipython ./evaluation.py'
|
||||||
archiveArtifacts artifacts: 'build_accuracy.txt, bilds_accuracy.jpg'
|
archiveArtifacts artifacts: 'build_accuracy.txt, bilds_accuracy.jpg'
|
||||||
|
Loading…
Reference in New Issue
Block a user