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

Git plugin does not support both multiple repositories and parameterized branch names

    XMLWordPrintable

Details

    • Improvement
    • Status: Closed (View Workflow)
    • Major
    • Resolution: Fixed
    • git-plugin
    • None
    • Ubuntu 12.10
      Sun Jdk

    Description

      The git plugin does not support both multiple repositories and parametrized branch names.

      1) Set up a cloneable repo release
      2) Put commit A into it
      3) Setup up another cloneable repo development cloned from release
      3.1) Put commit B into it
      4) Create branch feature in development
      $.1) Put commit C into it
      5) Create new jenkins job
      6) Add string parameter refs (no default value)
      7) Enable git plugin
      8) Add release repo as release
      9) Add development repo as development
      10) Setup branch field to development/$refs
      11) Launch build pass parameter value as **
      12) Build fails
      13) Reconfigure job remove release repo
      14) Launch build, pass parameter value as **
      15) Build passes
      16) Launch build, pass parameter value as feature
      17) Build passes building branch feature from remote development
      18) Launch build, pass parameter value as master
      19) Build passes building branch master from remote development

      Use case
      Add back in repo release names release
      In advanced section turn on pre build merge
      Configure repo release and branch master as the source ref to merge to
      Turn on git publisher
      Publish on success,
      Check Merge Results

      Now you can at any time instruct jenkins to merge from the development repo any branch and push it into the release repo under master. In affect it allows you to release a branch of master and store that release in the release repo. For more fun you can parametrize development as well. Allowing you to release any remote and any branch and put the results into release master

      Attachments

        Activity

          mpower_dodtsair Mike Power created issue -
          ndeloof Nicolas De Loof made changes -
          Field Original Value New Value
          Issue Type Bug [ 1 ] Improvement [ 4 ]

          Code changed in jenkins
          User: Jan Hruban
          Path:
          src/main/java/hudson/plugins/git/BranchSpec.java
          src/main/java/hudson/plugins/git/util/DefaultBuildChooser.java
          src/main/java/hudson/plugins/git/util/GitUtils.java
          src/main/java/hudson/plugins/git/util/InverseBuildChooser.java
          src/test/java/hudson/plugins/git/TestBranchSpec.java
          http://jenkins-ci.org/commit/git-plugin/4fc7f4447c990082e8322c42ebafd1f33a2e60aa
          Log:
          [FIXED JENKINS-17417] Expand Branch Specifier

          Expand Branch Specifier with build environment variables.

          Note that the Branch Specifier is not expanded for repository polling
          because no build environment is available at that time.

          scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Jan Hruban Path: src/main/java/hudson/plugins/git/BranchSpec.java src/main/java/hudson/plugins/git/util/DefaultBuildChooser.java src/main/java/hudson/plugins/git/util/GitUtils.java src/main/java/hudson/plugins/git/util/InverseBuildChooser.java src/test/java/hudson/plugins/git/TestBranchSpec.java http://jenkins-ci.org/commit/git-plugin/4fc7f4447c990082e8322c42ebafd1f33a2e60aa Log: [FIXED JENKINS-17417] Expand Branch Specifier Expand Branch Specifier with build environment variables. Note that the Branch Specifier is not expanded for repository polling because no build environment is available at that time.
          scm_issue_link SCM/JIRA link daemon made changes -
          Resolution Fixed [ 1 ]
          Status Open [ 1 ] Resolved [ 5 ]

          Code changed in jenkins
          User: Michael Clarke
          Path:
          src/main/java/hudson/plugins/git/BranchSpec.java
          src/main/java/hudson/plugins/git/util/DefaultBuildChooser.java
          src/main/java/hudson/plugins/git/util/GitUtils.java
          src/main/java/hudson/plugins/git/util/InverseBuildChooser.java
          src/test/java/hudson/plugins/git/TestBranchSpec.java
          http://jenkins-ci.org/commit/git-plugin/9f8bc3b63ad8859a400ba10c10013a0a7789f5c6
          Log:
          Merge pull request #183 from hrubi/expand-branch-spec

          [FIXED JENKINS-17417] Expand Branch Specifier

          Compare: https://github.com/jenkinsci/git-plugin/compare/ec521564afcc...9f8bc3b63ad8

          scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Michael Clarke Path: src/main/java/hudson/plugins/git/BranchSpec.java src/main/java/hudson/plugins/git/util/DefaultBuildChooser.java src/main/java/hudson/plugins/git/util/GitUtils.java src/main/java/hudson/plugins/git/util/InverseBuildChooser.java src/test/java/hudson/plugins/git/TestBranchSpec.java http://jenkins-ci.org/commit/git-plugin/9f8bc3b63ad8859a400ba10c10013a0a7789f5c6 Log: Merge pull request #183 from hrubi/expand-branch-spec [FIXED JENKINS-17417] Expand Branch Specifier Compare: https://github.com/jenkinsci/git-plugin/compare/ec521564afcc...9f8bc3b63ad8
          rtyler R. Tyler Croy made changes -
          Workflow JNJira [ 148252 ] JNJira + In-Review [ 192789 ]
          markewaite Mark Waite made changes -
          Status Resolved [ 5 ] Closed [ 6 ]

          People

            ndeloof Nicolas De Loof
            mpower_dodtsair Mike Power
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: