Host key verification failed on GitHub

Host key verification failed

If you delete the known_hosts file, you will encounter the following situations when operating vscode.

https://i.imgur.com/X6iFwg7.png

How to fix?

1
2
$ ssh-keyscan -t rsa github.com >> ~/.ssh/known_hosts
# github.com:22 SSH-2.0-babeld-17a926d7

After completion, you can continue to operate vscode.