Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-61120

SCM Checkout stage branches how to match remote pull request head with local build head

    Details

    • Similar Issues:

      Description

      Hi all,

      I'm having the below issue.

      I was change my code to use GIT Reference repository in Jenkinsfile code such as below.

      But so I send made a new pull request in GIT-HUB for the purpose of merge these changes into my master branch.

      But when the Pull-Request running I saw in my builder machine (workspace) its not downloading (fetching) the relevant Remote Pull-Request Head/Branch/ because in my workspace (builder-machine) local branch always checkout with the master branch and fetching from the master branch and not checkout for the correct Pull Request Head. 

       

      eg: Above screenshot is the way that my local workspace's .git > HEAD file looks like in the Pull Request I created after above code changes. And as you can see in the HEAD file it's automatically checkout in to the master branch instead of checking out into the relevant Pull-Request hash (tag). 

      • But below is the correct screenshot I captured from any of other Pull Requests, which should be the correct way to show the checkout branch or the HEAD.

       

      I hope you will understand my situation here? Please let me know if you guys need further information.

      I throughly suggest that I want some code to replace above Yellow color highlighted sections. 
      So please could anyone please give some advice regarding this issue ?  

       

        Attachments

          Activity

          Hide
          markewaite Mark Waite added a comment -

          The Jenkins issue tracker is not a support site or a question and answer site.

          The chat systems and mailing lists are much better suited to assist users with questions and answers.

          Show
          markewaite Mark Waite added a comment - The Jenkins issue tracker is not a support site or a question and answer site. The chat systems and mailing lists are much better suited to assist users with questions and answers.
          Hide
          amila_devops Amila Gunathilake added a comment -

          Mr. Mark Waite this is for your information (FYI)  -  I have created an issue ticket in the Mailing list.  So could you please reply to this via email ?  https://groups.google.com/forum/?utm_medium=email&utm_source=footer#!topic/jenkinsci-users/1h5mcbaYUQ8

          Thanks. Expecting your reply,
          Amila Khan

          Jenkins Customer Base
          India

           

          Show
          amila_devops Amila Gunathilake added a comment - Mr. Mark Waite this is for your information (FYI)  -  I have created an issue ticket in the Mailing list.  So could you please reply to this via email ?   https://groups.google.com/forum/?utm_medium=email&utm_source=footer#!topic/jenkinsci-users/1h5mcbaYUQ8 Thanks. Expecting your reply, Amila Khan Jenkins Customer Base India  

            People

            • Assignee:
              Unassigned
              Reporter:
              amila_devops Amila Gunathilake
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: