Added Jenkinsfile

This commit is contained in:
William
2018-12-05 08:37:46 +11:00
parent b0a608b5cd
commit de38f2829c

9
Jenkinsfile vendored
View File

@@ -3,8 +3,13 @@ pipeline {
stages {
stage('Get coriolis-data') {
steps {
sh '''cd ..
git clone https://github.com/edcd/coriolis-data.git'''
sh '''YES=`echo $GIT_BRANCH | awk -F / \'{print $2}\'`
export BRANCH=`git rev-parse --abbrev-ref $YES`
rm -rf $WORKSPACE/../coriolis-data
git clone https://github.com/edcd/coriolis-data.git $WORKSPACE/../coriolis-data
cd ../coriolis-data
git fetch --all
git checkout $BRANCH'''
}
}
}