add second Jenkinsfile and shell script
This commit is contained in:
parent
b2fc125f1c
commit
4d16ca6bcc
2
Jenkinsfile
vendored
2
Jenkinsfile
vendored
@ -31,7 +31,7 @@ pipeline {
|
|||||||
sh 'ls -a'
|
sh 'ls -a'
|
||||||
sh 'chmod +x create-dataset.sh'
|
sh 'chmod +x create-dataset.sh'
|
||||||
sh './create-dataset.sh'
|
sh './create-dataset.sh'
|
||||||
archiveArtifacts 'data/barcelona_weekends.train.csv, data/barcelona_weekends.dev.csv, data/barcelona_weekends.test.csv'
|
archiveArtifacts artifacts: 'data/barcelona_weekends.train.csv, data/barcelona_weekends.dev.csv, data/barcelona_weekends.test.csv', fingerprint: true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
29
Jenkinsfile-dataset-stats
Normal file
29
Jenkinsfile-dataset-stats
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
pipeline {
|
||||||
|
agent any
|
||||||
|
parameters([
|
||||||
|
buildSelector(
|
||||||
|
defaultSelector: lastSuccessful(),
|
||||||
|
description: 'Which build to use for copying artifacts',
|
||||||
|
name: 'BUILD_SELECTOR'
|
||||||
|
)
|
||||||
|
])
|
||||||
|
stages {
|
||||||
|
stage('Copy Artifacts') {
|
||||||
|
steps {
|
||||||
|
copyArtifacts fingerprintArtifacts: true, projectName: 'z-s444510-create-dataset', selector: buildParameter('BUILD_SELECTOR')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
stage('Calculate Dataset Statistics') {
|
||||||
|
steps {
|
||||||
|
sh 'chmod +x dataset-stats.sh'
|
||||||
|
sh './dataset-stats.sh'
|
||||||
|
}
|
||||||
|
post {
|
||||||
|
always {
|
||||||
|
archiveArtifacts artifacts: 'stats.txt.gz', fingerprint: true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
5
dataset-stats.sh
Normal file
5
dataset-stats.sh
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
zcat barcelona_weekends.dev.csv | wc -l > stats
|
||||||
|
|
||||||
|
gzip -c stats > stats.txt.gz
|
Loading…
Reference in New Issue
Block a user