今天在把sourceTree更新1.9.6.1版本之后,发现无论pull还是clone等所有本地和远端进行任何交流操作的时候都会报的错。
错误如下
git -c diff.mnemonicprefix=false -c core.quotepath=false fetch origin
FATAL ERROR: Network error: Connection refused
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
后来尝试用直接用git命令行操作发现是正常的。经过一番百度也没能找到解决办法,后来自己通过研究sourceTree的配置已解决。
方法如下:
新版本的SSH客户端选项默认为PuTTY/Plink,把它换成OpenSSH就可以了,它会默认git的SSH密钥,这时候
sourcetree就恢复正常啦~