[英]Git: Permission denied (publickey). fatal: Could not read from remote repository
[英]GIT permission denied (publickey) - Fatal could not read from remote repository
我有ssh -T git@github.com
命令返回成功验证。
我也有ssh-add -l -E sha256
返回 output。
但是git push -u origin main
返回
***@github.com: Permission denied (publickey).
fatal: Could not read from remote repository.
谁能帮我?
You are adding as a remote an HTTPS URL ( https://github.com/saumyaphilip/mgc_web.git )
这意味着您的 SSH 密钥根本没有使用。
至少尝试切换到 SSH:
cd /path/to/repository
git remote set-url origin git@github.com:saumyaphilip/mgc_web.git
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.