BitBucket SoureTree – The server’s host key is not cached in the registry

今天嘗試使用SourceTreePush一個新的Git Repos
誰不知 Push了很久都是停留在同一個output Windows
SourceTree Output Windows - The server's host key is not cached in the registry

git -c diff.mnemonicprefix=false -c core.quotepath=false push -v --tags --set-upstream origin master:master
Pushing to git@bitbucket.org:sharechiwai/SampleCode.git

The server's host key is not cached in the registry. You
have no guarantee that the server is the computer you
think it is.
The server's rsa2 key fingerprint is:
ssh-rsa 2048 97:xxxxxxxxxxxxxxxxxxxxxxx
If you trust this host, enter "y" to add the key to
PuTTY's cache and carry on connecting.

If you want to carry on connecting just once, without
adding the key to the cache, enter "n".
If you do not trust this host, press Return to abandon the
connection.

做了一會research之後終於找到解決方法了

解決方法:
大家可以使用Command Prompt之後輸入以下指令到 Source treePutty資料夾

cd "C:\Program Files (x86)\Atlassian\SourceTree\tools\putty"

之後執行以下指令到連接到 BitBucket

plink git@bitbucket.org

他便會出現上面的問題..叫你把Host Key CachRegistry
BitBucket SourceTree - The server's host key is not cached in the registry Solutions
完成後再嘗試使用Source Tree 去Push
這一次很快便可以把這一個Local Repos Push上了BitBucket

Hope you find it useful

Leave a Reply