pipeline { agent any stages { stage('copy artifacts') { steps { copyArtifacts fingerprintArtifacts: true, projectName: 's470607-create-dataset', selector: lastSuccessful() } } stage('stats') { steps { sh 'wc -l train.csv > stats.txt' sh 'wc -l test.csv >> stats.txt' sh 'wc -l valid.csv >> stats.txt' } } stage('archive artifacts') { steps { archiveArtifacts 'stats.txt' } } } }