我正在尝试使用 Git 扩展将自托管服务器存储库推送到 Git。我可以使用命令行完成,但使用 Git 扩展时会出现以下消息:
c:\Program Files (x86)\Git\bin\git.exe push --recurse-submodules=check "Specflow.Infrastructure.git" master:master
Done
fatal: The remote end hung up unexpectedly
我为存储库尝试了所有这些组合:
ssh://username@192.168.0.1/path/to/repository.git
ssh://192.168.0.1/path/to/repository.git
username@192.168.0.1/path/to/repository.git
192.168.0.1/path/to/repository.git
但同样的问题。但是,当我运行错误中提到的命令时:
c:\Program Files (x86)\Git\bin\git.exe push --recurse-submodules=check "Specflow.Infrastructure.git" master:master
有用!
我读了一些关于将HOME
环境变量设置为您的主目录的内容。我检查该目录是否包含该.ssh
文件夹,并且确实包含正确的详细信息。所以我设置了HOME
变量并重新启动了我的机器。同样的问题!
这个问题的其他答案是针对类似但不同的场景,其中在“完成”和“致命”这两个词之间产生特定的错误消息,因此需要这个问题。