ium_444380/Jenkinsfile.stats

31 lines
1022 B
Plaintext
Raw Normal View History

2022-03-27 12:52:38 +02:00
pipeline {
2022-04-03 19:39:11 +02:00
agent {
docker { image 'kamilguttmann/ium:latest' }
}
2022-03-27 12:52:38 +02:00
parameters {
buildSelector(
defaultSelector: lastSuccessful(),
description: 'Which build to use for copying artifacts',
name: 'BUILD_SELECTOR'
)
}
stages {
stage('Copy artifacts') {
steps {
copyArtifacts fingerprintArtifacts: true, projectName: 's444380-create-dataset', selector: buildParameter('BUILD_SELECTOR')
}
}
2022-04-03 19:40:54 +02:00
stage("Checkout git") {
2022-03-27 12:52:38 +02:00
steps {
checkout([$class: 'GitSCM', branches: [[name: '*/master']], extensions: [], userRemoteConfigs: [[credentialsId: 's444380', url: 'https://git.wmi.amu.edu.pl/s444380/ium_444380.git']]])
}
2022-04-03 19:40:54 +02:00
}
2022-03-27 12:52:38 +02:00
stage("Calcualte statistics") {
steps {
2022-04-03 19:39:11 +02:00
sh "python3 calc_stats.py | tee crime.stats.txt"
2022-03-27 12:52:38 +02:00
archiveArtifacts artifacts: "crime.stats.txt", onlyIfSuccessful: true
}
}
}
}