From 5c17a0b205cba190e0f222de7a5a6017f50258f8 Mon Sep 17 00:00:00 2001
From: TSC21 <n.marques21@hotmail.com>
Date: Sun, 27 Jan 2019 17:52:15 +0000
Subject: [PATCH] Jenkins CI: ROS msgs: clone by branch

---
 Jenkinsfile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Jenkinsfile b/Jenkinsfile
index 35d0c1387f..6489479ea5 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -480,7 +480,7 @@ pipeline {
           steps {
             sh('export')
             withCredentials([usernamePassword(credentialsId: 'px4buildbot_github_personal_token', passwordVariable: 'GIT_PASS', usernameVariable: 'GIT_USER')]) {
-              sh('git clone https://${GIT_USER}:${GIT_PASS}@github.com/PX4/px4_msgs.git')
+              sh('git clone https://${GIT_USER}:${GIT_PASS}@github.com/PX4/px4_msgs.git -b ${GIT_BRANCH}')
               sh('python msg/tools/uorb_to_ros_msgs.py msg/ px4_msgs/msg/')
               sh('cd px4_msgs; git status; git add .; git commit -a -m "Update message definitions `date`" || true')
               sh('cd px4_msgs; git push origin master || true')
-- 
GitLab