From 62ef43c15ba46cd14a8313e3c95b6806fdafbbda Mon Sep 17 00:00:00 2001 From: Zofia Galla Date: Sun, 28 Mar 2021 18:06:21 +0200 Subject: [PATCH] Add script and Jenkinsfile for zadanie 3.8 --- Jenkinsfile_stats | 21 +++++++++++++++++++++ jenkins_stats_script.sh | 4 ++++ 2 files changed, 25 insertions(+) create mode 100644 Jenkinsfile_stats create mode 100644 jenkins_stats_script.sh diff --git a/Jenkinsfile_stats b/Jenkinsfile_stats new file mode 100644 index 0000000..0cac29d --- /dev/null +++ b/Jenkinsfile_stats @@ -0,0 +1,21 @@ +pipeline { + agent any + stages { + stage('copyArtifacts') { + steps { + copyArtifacts fingerprintArtifacts: true, projectName: 's434684-create-dataset', selector: buildParameter('CREATE_DATASET_BUILD_SELECTOR') + } + } + stage('script stats') { + steps { + sh 'chmod +x jenkins_stats_script.sh' + sh './jenkins_stats_script.sh' + } + } + stage('archiveArtifacts') { + steps { + archiveArtifacts 'dataset-stats.txt' + } + } + } +} \ No newline at end of file diff --git a/jenkins_stats_script.sh b/jenkins_stats_script.sh new file mode 100644 index 0000000..9c865ca --- /dev/null +++ b/jenkins_stats_script.sh @@ -0,0 +1,4 @@ +#!/bin/bash +wc -l netflix_split_train.csv > dataset-stats.txt +wc -l netflix_split_test.csv >> dataset-stats.txt +wc -l netflix_split_validation.csv >> dataset-stats.txt \ No newline at end of file