GitHub SSH密钥声称未使用 [英] GitHub SSH Key claiming it is not used
问题描述
为什么,在设置=> SSH密钥下,我的GitHub帐户上写着;
由GitHub for Mac于2014年10月24日添加-从未使用
从未使用过?我已经用过了!我的个人资料上有很多贡献.从那台机器上来!
我有另一个钥匙说得很对;
最后一天使用的最后一次.
...那是来自另一台机器.
您的贡献可能来自该机器,但您需要检查如何设置遥控器
尝试以下命令:
git remote -v
这将列出您的遥控器
如果是这样的话
起源
单击SSH链接,然后将其复制.它应该以
开头git@github.com
然后,将其添加为遥控器-
git remote add origin git@github.com:....等
Why, under Settings => SSH keys, on my GitHub account does it say;
Added on Oct 24, 2014 by GitHub for Mac — Never used
Never used? I've used it! I've got plenty of contributions showing up on my profile. From that machine!
I have another key that says, quite rightly;
Last used within the last day.
...That one is from a different machine.
解决方案Your contributions may be from that machine, but you need to check how you have set up your remotes
try the following command:
git remote -v
That will list your remotes
If it is something like
origin https://github.com/......
You are connecting over https, and not SSH
You'll need to remove that remote -
git remote rm origin
Then, on your github repository page, see the following:
Click the SSH link, and copy that. It should start with
git@github.com
Then, add that as the remote-
git remote add origin git@github.com:.... etc
这篇关于GitHub SSH密钥声称未使用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!