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

git plugin "included regions" feature is bypassed when evaluating a merge commit

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Critical Critical
    • git-plugin
    • None

      If the built branch is updated via a merge commit rather than a change, the build is triggered regardless of whether the files updated in the merge match the included regions regexp or not.

      A test repo can be found at http://blank.org/memory/work/jenkins-bug/repo/jenkins-bug/regions-test.git. A config.xml is attached to this ticket. Note that commit 10c1279f32a5ffe9f6eabfe01aa360341144c263 in that repo (merge testbranch->master) triggers a build.

          [JENKINS-13580] git plugin "included regions" feature is bypassed when evaluating a merge commit

          This problem could be linked with the issue I raised
          where multiple commits in one push are not taken into account.

          https://issues.jenkins-ci.org/browse/JENKINS-13368

          Bertrand Latinville added a comment - This problem could be linked with the issue I raised where multiple commits in one push are not taken into account. https://issues.jenkins-ci.org/browse/JENKINS-13368

          Nathan Mehl added a comment -

          A potential fix can be found here:

          https://github.com/jenkinsci/git-plugin/pull/69

          Nathan Mehl added a comment - A potential fix can be found here: https://github.com/jenkinsci/git-plugin/pull/69

          Code changed in jenkins
          User: Nathan J. Mehl
          Path:
          src/main/java/hudson/plugins/git/GitAPI.java
          http://jenkins-ci.org/commit/git-plugin/3c83d2e4d38dd882cb7ddd096ff90c936e1f3e7a
          Log:
          [FIXED JENKINS-13580] Use 'git whatchanged' instead of 'git show'

          This forces file-by-file evaluation necessary for included/excluded
          regions to be applied correctly to merge commits.

          See: https://issues.jenkins-ci.org/browse/JENKINS-13580, which we
          believe is resolved here.

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Nathan J. Mehl Path: src/main/java/hudson/plugins/git/GitAPI.java http://jenkins-ci.org/commit/git-plugin/3c83d2e4d38dd882cb7ddd096ff90c936e1f3e7a Log: [FIXED JENKINS-13580] Use 'git whatchanged' instead of 'git show' This forces file-by-file evaluation necessary for included/excluded regions to be applied correctly to merge commits. See: https://issues.jenkins-ci.org/browse/JENKINS-13580 , which we believe is resolved here.

            Unassigned Unassigned
            nmehl Nathan Mehl
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: