From 8be8cdf2103ab8e8a8bb78db2a94bda1c1d547a3 Mon Sep 17 00:00:00 2001 From: Sheaza Date: Tue, 26 Mar 2024 19:05:13 +0100 Subject: [PATCH] add get stats script --- stats/Jenkinsfile | 27 +++++++++++++++++++++++++++ get_stats.sh => stats/get_stats.sh | 0 2 files changed, 27 insertions(+) create mode 100644 stats/Jenkinsfile rename get_stats.sh => stats/get_stats.sh (100%) diff --git a/stats/Jenkinsfile b/stats/Jenkinsfile new file mode 100644 index 0000000..62d6036 --- /dev/null +++ b/stats/Jenkinsfile @@ -0,0 +1,27 @@ +pipeline { + agent any + parameters { + buildSelector ( + defaultSelector: lastSuccessful(), + description: 'Which build to use for copying artifacts', + name: 'BUILD_SELECTOR' + ) + } + stages { + stage('Checkout repository') { + steps { + checkout scm + } + stage('Copy artifacts') { + steps { + copyArtifacts fingerprintArtifacts: true, projectName: 'z-s464980-create-dataset', selector: buildParameter('BUILD_SELECTOR') + } + } + stage('Get stats') { + steps { + sh "./get_stats.sh" + archiveArtifacts artifacts: 'stats.txt', onlyIfSuccessful: true + } + } + } +} \ No newline at end of file diff --git a/get_stats.sh b/stats/get_stats.sh similarity index 100% rename from get_stats.sh rename to stats/get_stats.sh