“无法连接到资源库”设置Github Jenkins插件时出错 [英] "Failed to connect to repository" Error while setting up Github Jenkins Plugin

查看:148
本文介绍了“无法连接到资源库”设置Github Jenkins插件时出错的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在将新回购库位输入新工作的源代码管理> Git>存储库URL部分时出现错误。我搜索了所有内容,尝试了许多不同的网址,但没有成功。



错误:

 无法连接到存储库:执行命令时出错:git ls-remote -h https://github.com/micdoodle8/Crossbow_Mod_2.git HEAD 

有什么想法?感谢。

解决方案

您可能需要在管理Jenkins - >配置系统 - >中设置git可执行文件的路径, Git - > Git Installations - > Git可执行文件的路径

例如,我在Windows中遇到同样的错误。我已经安装了git和chocolatey,并通过Powershell获得了位置:

  Get-Command git.exe |选择定义

在Unix中,您应该可以这样做:

 哪个git 


I am getting an error when inputting my repo location into the "Source Code Management > Git > Repository URL" section of a new Job. I have searched all around and tried many different URLs with no success.

Error:

Failed to connect to repository : Error performing command: git ls-remote -h https://github.com/micdoodle8/Crossbow_Mod_2.git HEAD

Any ideas? Thanks.

解决方案

You might need to set the path to your git executable in Manage Jenkins -> Configure System -> Git -> Git Installations -> Path to Git executable.

For example, I was getting the same error in Windows. I had installed git with chocolatey, and got the location via Powershell:

Get-Command git.exe | Select Definition

In Unix, you should be able to do:

which git

这篇关于“无法连接到资源库”设置Github Jenkins插件时出错的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆