Git 显示错误“似乎不是一个 git 存储库致命:远程端意外挂断”

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/4067381/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-10 09:23:00  来源:igfitidea点击:

Git shows the error "does not appear to be a git repository fatal: The remote end hung up unexpectedly"

git

提问by user493313

I just installed GIT in my CentOS Linux server and configured it. When I create a new repository using git initit works fine and gives output of the command also.
But whenever I try to clone the remote repository into my local computer folder it gives the following message:

我刚刚在 CentOS Linux 服务器中安装了 GIT 并对其进行了配置。当我使用git init它创建一个新的存储库时,它工作正常,并提供命令的输出。
但是每当我尝试将远程存储库克隆到我的本地计算机文件夹时,它都会给出以下消息:

fatal: '/public_html/repositories/git-test/.git' does not appear to be a git repository
fatal: The remote end hung up unexpectedly

Has anyone come across this issue, what could be the reason?

有没有人遇到过这个问题,可能是什么原因?

回答by kanaka

Your path may be incomplete. Perhaps your full path should be something more like this: /home/USER/public_html/repositories/git-test.

您的路径可能不完整。也许你的完整路径应该是更多的东西是这样的:/home/USER/public_html/repositories/git-test