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

CHANGE_FORK doesn't point to the user/repo when the fork name differs from the upstream name

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • None
    • Jenkins 2.176.1
      GitHub Branch Source Plugin 2.5.3
      SCM api plugin 2.6.3

      According to:

      https://javadoc.jenkins.io/plugin/scm-api/jenkins/scm/api/SCMHeadOrigin.Fork.html

      Given the upstream:
      https://github.com/super-mario-bros-pipelines/pipeline

      and the PR:

      https://github.com/super-mario-bros-pipelines/pipeline/pull/1

      which was created from:
      https://github.com/v1v/pipeline-1/tree/tes

      I'd expect the CHANGE_FORK env variable to point out to v1v/pipeline-1 but it does point out to the user v1v instead.

      The current set of env variables are shown below

      CHANGE_AUTHOR=v1v
      CHANGE_AUTHOR_DISPLAY_NAME=Victor Martinez
      CHANGE_BRANCH=tes
      CHANGE_FORK=v1v
      CHANGE_ID=1
      CHANGE_TARGET=master
      CHANGE_TITLE=chore: testing a pipeline
      CHANGE_URL=https://github.com/super-mario-bros-pipelines/pipeline/pull/1

            v2v Victor Martinez
            v2v Victor Martinez
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: