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

Lightweight checkout: commitId as branch name does not work when expanded

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • Minor
    • git-plugin
    • Jenkins 2.375.2, Git Plugin 5.0.0

    Description

      The Git plugin should now be able to expand environment variables and use them for the checkouts, such as the branch specifier. This works completely fine when specifying a branch name. It also worked fine when entering a commit ID manually. 

      However, it fails when I combine the two and add the commit ID as a parameter, which is then used for the branch (see attached screenshot). The plugin will treat it as a regular branch name and fails to do the checkout.

      stderr: fatal: couldn't find remote ref refs/heads/62f7ad718b0d427b7fd0cb0fe15a615308c41d92
      My workaround for now is to use the branch name instead of the commit hash.

      Attachments

        Activity

          People

            Unassigned Unassigned
            vogtmh Maximilian
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated: