38 lines
873 B
Plaintext
38 lines
873 B
Plaintext
pipeline {
|
|
agent {
|
|
docker { image 'ubuntu:latest' }
|
|
}
|
|
|
|
parameters{
|
|
buildSelector(
|
|
defaultSelector: lastSuccessful(),
|
|
name: 'BUILD_SELECTOR',
|
|
description: 'Build selector for Copy artifact'
|
|
)
|
|
}
|
|
|
|
|
|
stages {
|
|
stage("Check out from version control") {
|
|
steps {
|
|
checkout scm
|
|
}
|
|
}
|
|
|
|
|
|
stage("Shell Script") {
|
|
steps {
|
|
copyArtifacts(
|
|
fingerprintArtifacts: true,
|
|
projectName: 's444354-create-dataset',
|
|
selector: buildParameter('BUILD_SELECTOR')
|
|
)
|
|
steps {
|
|
sh "chmod u+x ./script2.sh"
|
|
sh " ./script2.sh"
|
|
archiveArtifacts 'num_of_lines.txt'
|
|
|
|
}
|
|
}
|
|
}
|
|
} |