Git https://存储库没有找到,尽管它存在 [英] Git https:// repository not found though it exists

查看:130
本文介绍了Git https://存储库没有找到,尽管它存在的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在github上有一个私人回购站。

我尝试更换遥控器,但无法再继续播放。

  ls-remote https://github.com/xxxxx/xxxxx.git 

给了我这个

remote:找不到存储库。 '找不到





我将git从1.9.5升级到2.2.1,看看它是否有帮助



升级后,我在存储库上执行了一个新的ls-remote,并要求接受新证书。我没有。



这并没有解决问题。



SSH URL 尽管完美地工作
所以我通过添加SSH URL作为远程来源解决了问题



为什么https:// url是未找到让我感到困惑。
任何人有任何想法?

解决方案

我认为,因为它是一个私人回购,它似乎不存在用于匿名访问。如果您使用https url,它将发送匿名请求,而ssh url使用您的ssh证书和私钥建立连接。



不确定如何使它与github正常工作,但请尝试在URL中指定一个用户名,例如 ls-remote https://youusername@github.com/xxxxx/xxxxx.git



这里有一些线索,我相信:


I have a private repo on github. It's location was changed.

I tried changing the remote but I wasn't able to push anymore.

ls-remote https://github.com/xxxxx/xxxxx.git

gave me this

remote: Repository not found.
fatal: repository '
https://github.com/xxxxx/xxxxx.git/' not found

I upgraded git from 1.9.5 to 2.2.1 to see if it would help

After the upgrade I did a new ls-remote on the repository and it asked to accept a new certificate. I did.

This didn't remove the problem

Doing a ls-remote on the SSH URL url though works perfectly So I fixed the problem by adding the SSH URL as remote origin

Why the https:// url is Not found keeps me puzzled. Anyone has any idea?

解决方案

I think that as it is a private repo, it appears as non-existent for anonymous access. If you use https url, it sends anonymous request, while ssh url uses your ssh credentials and private key to establish connection.

Not sure how to make it work properly with github, but try specifying a username in the url such as ls-remote https://youusername@github.com/xxxxx/xxxxx.git.

Here some clues, I believe: Is there a way to skip password typing when using https:// on GitHub?

这篇关于Git https://存储库没有找到,尽管它存在的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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