当我遇到这个错误时,我试图将代码从存储库中推开:
没有匿名写访问权限。
我遵循了https://stackoverflow.com/questions/60757334/git-push-from-vs-code-no-anonymous-write-access-authentication-failed中提到的步骤,但仍然出现了相同的错误。
我需要对该问题中提到的进程作出一些澄清。
做完cat ~/.ssh/id_ed25519.pub
之后,我看到了格式的密钥
ssh-ed25519 <key> <email>
我是否需要复制key field
of GitHub帐户中的全部内容,如key+email或只复制密钥?
除了澄清之外,还有其他解决办法吗?
我根据收到的答案复制了所有的内容。但随后,我将遥控器从https
更改为ssh
链接,然后在推送时得到这个错误:
sign_and_send_pubkey: signing failed: agent refused operation
git@github.com: Permission denied (publickey).
fatal: Could not read from remote repository.
Please make sure you have the correct access rights and the repository exists.
发布于 2021-11-14 14:26:17
ssh-ed25519 <key> <email>
发布于 2021-11-14 13:36:25
将公共密钥something.pub
中的所有内容复制到GitHub SSH设置页面的key
部分。
关键应该是这样:ssh-rsa <key> <username>@<machine_name>
发布于 2021-11-15 16:40:06
在将代码推到remote:在GitHub上测试SSH连接之前,您可以在这里阅读来测试SSH连接。
https://stackoverflow.com/questions/69963454
复制相似问题