36 lines
1.2 KiB
Groovy
36 lines
1.2 KiB
Groovy
pipeline {
|
|
agent any
|
|
|
|
parameters{
|
|
string(
|
|
defaultValue: 'maciejsobkowiak',
|
|
description: 'Kaggle username',
|
|
name: 'username',
|
|
trim: false
|
|
)
|
|
}
|
|
|
|
stages {
|
|
stage('checkout: Check out from version control') {
|
|
steps {
|
|
git branch: 'master',
|
|
url: 'https://git.wmi.amu.edu.pl/s434784/ium_434784'
|
|
}
|
|
}
|
|
stage('sh: Shell Script') {
|
|
steps {
|
|
// withEnv(['KAGGLE_USERNAME=$params.username',
|
|
// 'KAGGLE_KEY=$params.key' ]) {
|
|
// sh "KAGGLE_USERNAME=${params.username} KAGGLE_KEY=${params.key} kaggle datasets download -d szamil/who-suicide-statistics"
|
|
// sh 'echo KAGGLE_USERNAME: $KAGGLE_USERNAME'
|
|
// sh 'kaggle datasets download -d szamil/who-suicide-statistics'
|
|
// }
|
|
withEnv(["KAGGLE_USERNAME=${params.username}",
|
|
"KAGGLE_KEY=${params.key}" ]) {
|
|
sh 'echo KAGGLE_USERNAME: $KAGGLE_USERNAME'
|
|
sh 'kaggle datasets list'
|
|
}
|
|
}
|
|
}
|
|
}
|
|
} |