【发布时间】:2020-11-26 19:11:33
【问题描述】:
我有一个托管在 AWS 上的 git 存储库,我正在尝试执行:
git push -u origin master
我收到以下错误:
fatal: http://[URL]/[Repo-Name].git/info/refs not valid: is this a git repository?
我在这里尝试了答案但没有成功: Git .git/info/refs not valid: is this a git repository?
fatal: .git/info/refs not valid: is this a git repository?
对于这个错误有什么可能的解决方案?
当我使用时
git remote -v
我得到:
origin http://[URL]/test1.git (fetch)
origin http://[URL]/test1.git (push)
【问题讨论】:
-
需要更多信息。上次尝试推送到远程是否发生了什么?您是否在推送过程中失去了 Internet 连接?另外,添加
git remote -v的输出。可能 URL 不同。 -
我添加了git remote -v的o/p。其中 test1 是 repo 名称,这是我第一次进入 git。互联网连接良好。