在克隆git仓库时,我收到错误fatal: refusing to work with credential missing host field
早些时候我得到了ssl握手错误,所以,在git配置文件中添加以下内容后,现在我被提到的致命错误卡住了。
sslCert = ~/xyz.crt
sslKey = ~/xyz.key
sslVerify = false
sslCertPasswordProtected = false
我也试着在下面添加,但没有成功:
[url "https://hostname"]
insteadOf = git://hostname
git credential approve
protocol=https
host=www.abc.com
username=yuyiuyiuy
password=78yhkjh
warning: ----------------- SECURITY WARNING ----------------
warning: | TLS certificate verification has been disabled! |
warning: ---------------------------------------------------
warning: HTTPS connections may not be secure. See https://aka.ms/gcm/tlsverify for more information.
warning: failed to probe 'http(s)://www.abc.com/' to detect provider
warning: An error occurred while sending the request.
warning: see https://aka.ms/gcm/autodetect for more information.
同样,如下所示
protocol=https
host=www.abc.com
username=yuyiuyiuy
password=78yhkjh
url=<git repo path>
fatal:拒绝使用缺少主机字段的凭据
2条答案
按热度按时间4dbbbstv1#
这帮助了我:
e0bqpujr2#
对我来说,在MacOS上,当我试图将.gitconfig文件重命名为.xgitconfig(或者只是删除git的全局配置文件)时,一切都很好,通过HTTPS克隆远程存储库也很好。