[英]Adding an SSH Key to Github from Git
我第一次嘗試將最近創建的 SSH 密鑰從 windows 上的 Git 添加到 Git-hub。 當在 Git 中輸入“$ SSH -T git@github.com”時,它會彈出一個密鑰指紋,我不認識它列出的是什么。 抱歉,這是我第一次這樣做。 它只說“ED2219 密鑰指紋是(我不認識后面的部分。”)
它問我是否要繼續選擇(是/否/[指紋])? 我沒有嘗試過任何解決方案來解決我的問題。
# Copies the contents of the id_ed25519.pub file to your clipboard
clip < ~/.ssh/id_ed25519.pub
提示:如果
clip
不起作用,您可以在C:/../User/.ssh
中找到隱藏的.ssh
文件夾,在您喜歡的文本編輯器中打開該文件,然后將其復制到剪貼板。
## Attempts to ssh to GitHub
$ ssh -T git@github.com
## output
> The authenticity of host 'github.com (IP ADDRESS)' can't be established.
> Ed25519 key fingerprint is SHA256:+DiY3wvvV6TuJJhbpZisF/zLDA0zPMSvHdkr4UvCOqU
> Are you sure you want to continue connecting (yes/no)?
SHA256:+DiY3wvvV6TuJJhbpZisF/zLDA0zPMSvHdkr4UvCOqU
)是否與GitHub 的 SSH 密鑰指紋之一相同yes
# Output
Hi USERNAME! You've successfully authenticated,
but GitHub does not provide shell access.
如果你有相同的 output,那么一切都很好,你應該可以使用 shh 和 GitHub
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.