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 { stages {
stage('Get coriolis-data') { stage('Get coriolis-data') {
steps { steps {
sh '''cd .. sh '''YES=`echo $GIT_BRANCH | awk -F / \'{print $2}\'`
git clone https://github.com/edcd/coriolis-data.git''' 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'''
} }
} }
} }