tortoiseGit fatal: Could not read from remote repository.

时间:2024-03-15 10:29:31

1、问题场景:

使用tortoiseGit工具pull代码的时候报错

tortoiseGit fatal: Could not read from remote repository.

tortoiseGit fatal: Could not read from remote repository.

git.exe pull --progress -v --no-rebase "origin"

fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

无法从存储库中读取,可能是因为权限问题。

由于tortoisegit使用的是putty的.ppk格式的**,而gitlab必须使用rsa**,因此使用其自带的工具,在开始菜单里找到tortoisegit,选择他的puttygen工具来生成**

2、解决方式

点击开始菜单,按照图示操作

tortoiseGit fatal: Could not read from remote repository.

tortoiseGit fatal: Could not read from remote repository.

点击generate,此时会开始生成**,时间比较长

tortoiseGit fatal: Could not read from remote repository.

成功之后,点击 sava private key,save键把私钥保存为.ppk格式,选择一个目录保存test.ppk

tortoiseGit fatal: Could not read from remote repository.

然后,开始菜单,找到pageant

tortoiseGit fatal: Could not read from remote repository.'

点击add key,选择刚才保存的test.ppk,添加成功。

tortoiseGit fatal: Could not read from remote repository.

鼠标右键,选择TortoiseGit——>setting。signiing key选择上一步保存的文件。

tortoiseGit fatal: Could not read from remote repository.

最后一步,修改ssh。

tortoiseGit fatal: Could not read from remote repository.