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

Report primary branch

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed (View Workflow)
    • Priority: Minor
    • Resolution: Fixed
    • Component/s: git-plugin
    • Labels:
      None
    • Similar Issues:

      Description

      Implement JENKINS-38718 for Git

        Attachments

          Issue Links

            Activity

            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Stephen Connolly
            Path:
            pom.xml
            src/main/java/jenkins/plugins/git/AbstractGitSCMSource.java
            src/main/java/jenkins/plugins/git/GitRemoteHeadRefAction.java
            src/test/java/jenkins/plugins/git/AbstractGitSCMSourceTest.java
            http://jenkins-ci.org/commit/git-plugin/7164cf26db822acd145cbad4d18f45af89e9533a
            Log:
            JENKINS-40834 Should implement for 2.6.x branch but...

            • Seems like the JGit Impl is not actually making the remote's HEAD available.
            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Stephen Connolly Path: pom.xml src/main/java/jenkins/plugins/git/AbstractGitSCMSource.java src/main/java/jenkins/plugins/git/GitRemoteHeadRefAction.java src/test/java/jenkins/plugins/git/AbstractGitSCMSourceTest.java http://jenkins-ci.org/commit/git-plugin/7164cf26db822acd145cbad4d18f45af89e9533a Log: JENKINS-40834 Should implement for 2.6.x branch but... Seems like the JGit Impl is not actually making the remote's HEAD available.
            Hide
            stephenconnolly Stephen Connolly added a comment -

            https://github.com/jenkinsci/git-plugin/tree/jenkins-40834 in theory should work... but I'm only ever seeing refs/heads/master reported by JGit as the HEAD ref... while if I go and manually inspect git ls-remote --symref the cache git repo or the origin sample repo, both of those have HEAD as refs/heads/new-primary

            Probably there is something wrong in JGit and perhaps also in out git-client... WDYT Mark Waite

            Show
            stephenconnolly Stephen Connolly added a comment - https://github.com/jenkinsci/git-plugin/tree/jenkins-40834 in theory should work... but I'm only ever seeing refs/heads/master reported by JGit as the HEAD ref... while if I go and manually inspect git ls-remote --symref the cache git repo or the origin sample repo, both of those have HEAD as refs/heads/new-primary Probably there is something wrong in JGit and perhaps also in out git-client... WDYT Mark Waite
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Stephen Connolly
            Path:
            src/main/java/jenkins/plugins/git/AbstractGitSCMSource.java
            src/main/java/jenkins/plugins/git/GitRemoteHeadRefAction.java
            src/test/java/jenkins/plugins/git/AbstractGitSCMSourceTest.java
            http://jenkins-ci.org/commit/git-plugin/f97f8605c5dc4001b9ba7e2d46a8f5dda2674c4b
            Log:
            JENKINS-40834 Should implement for 2.6.x branch but...

            • Seems like the JGit Impl is not actually making the remote's HEAD available.
            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Stephen Connolly Path: src/main/java/jenkins/plugins/git/AbstractGitSCMSource.java src/main/java/jenkins/plugins/git/GitRemoteHeadRefAction.java src/test/java/jenkins/plugins/git/AbstractGitSCMSourceTest.java http://jenkins-ci.org/commit/git-plugin/f97f8605c5dc4001b9ba7e2d46a8f5dda2674c4b Log: JENKINS-40834 Should implement for 2.6.x branch but... Seems like the JGit Impl is not actually making the remote's HEAD available.
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Stephen Connolly
            Path:
            pom.xml
            src/main/java/jenkins/plugins/git/AbstractGitSCMSource.java
            src/test/java/jenkins/plugins/git/AbstractGitSCMSourceTest.java
            http://jenkins-ci.org/commit/git-plugin/266413c635d1ff2c6e551a54869937fc58f6d4ae
            Log:
            JENKINS-40834 Pick up https://github.com/jenkinsci/git-client-plugin/pull/236

            Compare: https://github.com/jenkinsci/git-plugin/compare/7164cf26db82...266413c635d1

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Stephen Connolly Path: pom.xml src/main/java/jenkins/plugins/git/AbstractGitSCMSource.java src/test/java/jenkins/plugins/git/AbstractGitSCMSourceTest.java http://jenkins-ci.org/commit/git-plugin/266413c635d1ff2c6e551a54869937fc58f6d4ae Log: JENKINS-40834 Pick up https://github.com/jenkinsci/git-client-plugin/pull/236 Compare: https://github.com/jenkinsci/git-plugin/compare/7164cf26db82...266413c635d1
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Stephen Connolly
            Path:
            pom.xml
            http://jenkins-ci.org/commit/git-plugin/d2c51dc7ccb7f4f77b589ac6c83ac4077ba89037
            Log:
            JENKINS-40834 Pick up latest -SNAPSHOT

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Stephen Connolly Path: pom.xml http://jenkins-ci.org/commit/git-plugin/d2c51dc7ccb7f4f77b589ac6c83ac4077ba89037 Log: JENKINS-40834 Pick up latest -SNAPSHOT
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Stephen Connolly
            Path:
            src/main/java/org/jenkinsci/plugins/gitclient/CliGitAPIImpl.java
            src/main/java/org/jenkinsci/plugins/gitclient/GitClient.java
            src/main/java/org/jenkinsci/plugins/gitclient/JGitAPIImpl.java
            src/main/java/org/jenkinsci/plugins/gitclient/RemoteGitImpl.java
            src/test/java/org/jenkinsci/plugins/gitclient/GitAPITestCase.java
            http://jenkins-ci.org/commit/git-client-plugin/64f43038d0723c3c313d6bed66edea190b17ba51
            Log:
            JENKINS-40834 Add an API to resolve symbolic refs

            • Sadly JGit needs to try and guess
            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Stephen Connolly Path: src/main/java/org/jenkinsci/plugins/gitclient/CliGitAPIImpl.java src/main/java/org/jenkinsci/plugins/gitclient/GitClient.java src/main/java/org/jenkinsci/plugins/gitclient/JGitAPIImpl.java src/main/java/org/jenkinsci/plugins/gitclient/RemoteGitImpl.java src/test/java/org/jenkinsci/plugins/gitclient/GitAPITestCase.java http://jenkins-ci.org/commit/git-client-plugin/64f43038d0723c3c313d6bed66edea190b17ba51 Log: JENKINS-40834 Add an API to resolve symbolic refs Sadly JGit needs to try and guess
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Stephen Connolly
            Path:
            src/main/java/org/jenkinsci/plugins/gitclient/JGitAPIImpl.java
            http://jenkins-ci.org/commit/git-client-plugin/2cb2fc176d47bf1dc0d8017e9bfd567d4fa453e5
            Log:
            JENKINS-40834 Bingo! A nasty hack gets us the symref info for JGit pending their implementation of same

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Stephen Connolly Path: src/main/java/org/jenkinsci/plugins/gitclient/JGitAPIImpl.java http://jenkins-ci.org/commit/git-client-plugin/2cb2fc176d47bf1dc0d8017e9bfd567d4fa453e5 Log: JENKINS-40834 Bingo! A nasty hack gets us the symref info for JGit pending their implementation of same
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Stephen Connolly
            Path:
            src/main/java/org/jenkinsci/plugins/gitclient/CliGitAPIImpl.java
            src/main/java/org/jenkinsci/plugins/gitclient/GitClient.java
            src/main/java/org/jenkinsci/plugins/gitclient/JGitAPIImpl.java
            http://jenkins-ci.org/commit/git-client-plugin/c5edec5f795d8bec1c46dccb5b404cde9ecd9b17
            Log:
            JENKINS-40834 Probably safest to let the consumer of the API decide what to do if the is no symbolc ref support

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Stephen Connolly Path: src/main/java/org/jenkinsci/plugins/gitclient/CliGitAPIImpl.java src/main/java/org/jenkinsci/plugins/gitclient/GitClient.java src/main/java/org/jenkinsci/plugins/gitclient/JGitAPIImpl.java http://jenkins-ci.org/commit/git-client-plugin/c5edec5f795d8bec1c46dccb5b404cde9ecd9b17 Log: JENKINS-40834 Probably safest to let the consumer of the API decide what to do if the is no symbolc ref support
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Stephen Connolly
            Path:
            src/test/java/org/jenkinsci/plugins/gitclient/CliGitAPIImplTest.java
            src/test/java/org/jenkinsci/plugins/gitclient/GitAPITestCase.java
            src/test/java/org/jenkinsci/plugins/gitclient/JGitAPIImplTest.java
            src/test/java/org/jenkinsci/plugins/gitclient/JGitApacheAPIImplTest.java
            http://jenkins-ci.org/commit/git-client-plugin/f5e22966ba11c5e5f309d5e9a0de7adcd99dd6c7
            Log:
            JENKINS-40834 Fix tests to apply for correct versions of the git clients

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Stephen Connolly Path: src/test/java/org/jenkinsci/plugins/gitclient/CliGitAPIImplTest.java src/test/java/org/jenkinsci/plugins/gitclient/GitAPITestCase.java src/test/java/org/jenkinsci/plugins/gitclient/JGitAPIImplTest.java src/test/java/org/jenkinsci/plugins/gitclient/JGitApacheAPIImplTest.java http://jenkins-ci.org/commit/git-client-plugin/f5e22966ba11c5e5f309d5e9a0de7adcd99dd6c7 Log: JENKINS-40834 Fix tests to apply for correct versions of the git clients
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Mark Waite
            Path:
            src/main/java/org/jenkinsci/plugins/gitclient/CliGitAPIImpl.java
            src/main/java/org/jenkinsci/plugins/gitclient/GitClient.java
            src/main/java/org/jenkinsci/plugins/gitclient/JGitAPIImpl.java
            src/main/java/org/jenkinsci/plugins/gitclient/RemoteGitImpl.java
            src/test/java/org/jenkinsci/plugins/gitclient/CliGitAPIImplTest.java
            src/test/java/org/jenkinsci/plugins/gitclient/GitAPITestCase.java
            src/test/java/org/jenkinsci/plugins/gitclient/JGitAPIImplTest.java
            src/test/java/org/jenkinsci/plugins/gitclient/JGitApacheAPIImplTest.java
            http://jenkins-ci.org/commit/git-client-plugin/85501392a154ed9b48e8e885a4fb1055fbfb3746
            Log:
            Merge pull request #236 from stephenc/jenkins-40834

            JENKINS-40834 Add an API to resolve symbolic refs

            Compare: https://github.com/jenkinsci/git-client-plugin/compare/85f78b9ca80e...85501392a154

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Mark Waite Path: src/main/java/org/jenkinsci/plugins/gitclient/CliGitAPIImpl.java src/main/java/org/jenkinsci/plugins/gitclient/GitClient.java src/main/java/org/jenkinsci/plugins/gitclient/JGitAPIImpl.java src/main/java/org/jenkinsci/plugins/gitclient/RemoteGitImpl.java src/test/java/org/jenkinsci/plugins/gitclient/CliGitAPIImplTest.java src/test/java/org/jenkinsci/plugins/gitclient/GitAPITestCase.java src/test/java/org/jenkinsci/plugins/gitclient/JGitAPIImplTest.java src/test/java/org/jenkinsci/plugins/gitclient/JGitApacheAPIImplTest.java http://jenkins-ci.org/commit/git-client-plugin/85501392a154ed9b48e8e885a4fb1055fbfb3746 Log: Merge pull request #236 from stephenc/jenkins-40834 JENKINS-40834 Add an API to resolve symbolic refs Compare: https://github.com/jenkinsci/git-client-plugin/compare/85f78b9ca80e...85501392a154
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Mark Waite
            Path:
            pom.xml
            src/main/java/jenkins/plugins/git/AbstractGitSCMSource.java
            src/main/java/jenkins/plugins/git/GitRemoteHeadRefAction.java
            src/test/java/jenkins/plugins/git/AbstractGitSCMSourceTest.java
            http://jenkins-ci.org/commit/git-plugin/497870f9c90e25ec71b4d27690932e70e1578ddf
            Log:
            Merge pull request #487 from jenkinsci/jenkins-40834

            JENKINS-40834 Report the primary branch

            Compare: https://github.com/jenkinsci/git-plugin/compare/a2ac1aef109d...497870f9c90e

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Mark Waite Path: pom.xml src/main/java/jenkins/plugins/git/AbstractGitSCMSource.java src/main/java/jenkins/plugins/git/GitRemoteHeadRefAction.java src/test/java/jenkins/plugins/git/AbstractGitSCMSourceTest.java http://jenkins-ci.org/commit/git-plugin/497870f9c90e25ec71b4d27690932e70e1578ddf Log: Merge pull request #487 from jenkinsci/jenkins-40834 JENKINS-40834 Report the primary branch Compare: https://github.com/jenkinsci/git-plugin/compare/a2ac1aef109d...497870f9c90e
            Hide
            stephenconnolly Stephen Connolly added a comment -

            git-plugin 3.2.0

            Show
            stephenconnolly Stephen Connolly added a comment - git-plugin 3.2.0

              People

              • Assignee:
                stephenconnolly Stephen Connolly
                Reporter:
                stephenconnolly Stephen Connolly
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: