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

Git client support multiple patterns in getRemoteReferences

    Details

    • Type: Improvement
    • Status: Open (View Workflow)
    • Priority: Minor
    • Resolution: Unresolved
    • Component/s: git-client-plugin
    • Labels:
      None
    • Environment:
      Windows 32, 64 - All supported versions
      Git-Client plugin version 2.5.0
      Jenkins minimum version 1.625.3
    • Similar Issues:

      Description

      So that git-plugin discoverBranches can discover non standard branches i.e. branches not in refs/heads/* but other paths (as provided) by ref specs, the git-client plugin needs to be able to accept "pattern" for gitRemoteReferences because current functionality will only accept a single pattern and an attempt to put multiple patterns in the current implementation causes the "pattern" argument to concatenate the patterns as single string which doesn't appear to match anything

        Attachments

          Activity

          Hide
          markewaite Mark Waite added a comment -

          Can't you achieve what you're requesting by using multiple refspecs?

          The git drop down (for GitHub and BitBucket and Git) allows adding more refspecs,.

          Show
          markewaite Mark Waite added a comment - Can't you achieve what you're requesting by using multiple refspecs? The git drop down (for GitHub and BitBucket and Git) allows adding more refspecs,.
          Hide
          jolykins MARK ANDREWS added a comment -

          Yes however it appears (happy to be wrong) that the pattern passed in to git-client getreferences is a string that if passed multiple patterns would be interpreted as a single pattern and thus would not match. Im only making that assumption based on the fact that each argument is added to the arguments collection and multiple patterns would be added as a single argument. I dont know how this expands when git ls-remote is then actually called

          Show
          jolykins MARK ANDREWS added a comment - Yes however it appears (happy to be wrong) that the pattern passed in to git-client getreferences is a string that if passed multiple patterns would be interpreted as a single pattern and thus would not match. Im only making that assumption based on the fact that each argument is added to the arguments collection and multiple patterns would be added as a single argument. I dont know how this expands when git ls-remote is then actually called

            People

            • Assignee:
              Unassigned
              Reporter:
              jolykins MARK ANDREWS
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated: