Hi All,
I am trying to Set up Jenkins Job for my GitHub project having C# script. But i am facing below error
ERROR: Error fetching remote repo 'origin'
hudson.plugins.git.GitException: Failed to fetch from g...@github.com:xxxx/xxxx.git
at hudson.plugins.git.GitSCM.fetchFrom(GitSCM.java:792)
at hudson.plugins.git.GitSCM.retrieveChanges(GitSCM.java:1048)
at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1079)
at hudson.scm.SCM.checkout(SCM.java:485)
at hudson.model.AbstractProject.checkout(AbstractProject.java:1269)
at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:604)
at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:86)
at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:529)
at hudson.model.Run.execute(Run.java:1741)
at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
at hudson.model.ResourceController.execute(ResourceController.java:98)
at hudson.model.Executor.run(Executor.java:410)
Caused by: hudson.plugins.git.GitException: Command "git.exe -c core.askpass=true fetch --tags --progress g...@github.com:xxxx/xxxx.git +refs/heads/xxxx:refs/remotes/origin/xxxx" returned status code 1:
stdout:
stderr: error: cannot lock ref 'refs/remotes/origin/xxxx': 'refs/remotes/origin/xxxx/xxxx' exists; cannot create 'refs/remotes/origin/xxxx'
From github.com:xxxx/xxxx
! [new branch] xxxx-> origin/xxxx (unable to update local ref)
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1719)
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:1463)
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.access$300(CliGitAPIImpl.java:63)
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$1.execute(CliGitAPIImpl.java:314)
at hudson.plugins.git.GitSCM.fetchFrom(GitSCM.java:790)
... 11 more
ERROR: null
Finished: FAILURE
Can someone help me in providing the checklist or configuring job document for Jenkins to ensure i am following right steps.
And also i am having below clarifications
1) Is there any procedure to execute git commands in order that needs to be configured in Jenkins?[like init,git fetch,git clone e.t.c]
2) Where we need to execute git commands ?
3) Should we have copy of repo in our local system because executing git commands /Configuring job?
Thanks in Advance,
Brunda.