简体   繁体   English

致命:无法访问“https://github.com/SOME_NAME/SOME_PROJECT.git/”:请求的网址返回错误:403

[英]fatal: unable to access 'https://github.com/SOME_NAME/SOME_PROJECT.git/': The requested URL returned error: 403

 git push
 remote: Permission to newGithubAccount/newGithubAccountProject.git denied to myOldGithubAccount.
 fatal: unable to access 'https://github.com/newGithubAccount/newGithubAccountProject.git/': The requested URL returned error: 403

I got the 403 error, I know it's that incorrect access was found, and the error message clearly shows me why: Because my git push was using my previous github account's credentials, however, I've updated my git global config and generated new .ssh/id_rsa and added the ssh key into my new github account. 我得到了403错误,我知道发现了错误的访问,并且错误消息清楚地告诉我原因:因为我的git push使用了我以前的github帐户的凭据,但是,我已经更新了我的git全局配置并生成了新的.ssh/id_rsa并将ssh密钥添加到我的新github帐户中。 But still this error persists, I've searched extensively on this site and on Github.help page, but still no luck, please help. 但是这个错误仍然存​​在,我在这个网站和Github.help页面上进行了大量搜索,但仍然没有运气,请帮忙。

I think I need to somehow completely clear my cache for the previous github account or delete it, then I could access github with my new account. 我想我需要以某种方式完全清除我之前的github帐户的缓存或删除它,然后我可以使用我的新帐户访问github。 Or else ways, please advise! 或者方法,请指教! Thanks a lot! 非常感谢!

The previous remote is configured to use the HTTP protocol. 以前的远程配置为使用HTTP协议。 You can use the set-url remote command to update your remote to use the SSH based protocol. 您可以使用set-url remote命令更新远程以使用基于SSH的协议。

git remote set-url origin git@github.com:newGithubAccount/newGithubAccountProject.git

https://help.github.com/articles/changing-a-remote-s-url/ https://help.github.com/articles/changing-a-remote-s-url/

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 致命:无法访问“ https://github.com/MyName/MyRepo.git/”:请求的URL返回错误:403 - fatal: unable to access 'https://github.com/MyName/MyRepo.git/': The requested URL returned error: 403 致命:无法访问“https://github.com/usename/my-project.git/”:请求的 URL 返回错误:403 Mac - fatal: unable to access 'https://github.com/usename/my-project.git/': The requested URL returned error: 403 Mac remote:拒绝XXX / .git的权限给YYY。 致命:无法访问“ https://github.com/XXX//”:请求的URL返回错误:403 - remote: Permission to XXX/.git denied to YYY. fatal: unable to access 'https://github.com/XXX//': The requested URL returned error: 403 我该如何解决致命问题:无法访问“https://github.com/MTaha57/Build-Portfolio-.git/”:请求的 URL 返回错误:403 - How can i resolve fatal: unable to access 'https://github.com/MTaha57/Build-Portfolio-.git/': The requested URL returned error: 403 致命:无法访问“https://git-codecommit.eu-west-1.amazonaws.com/v1/repos/myrepo/”:请求的 URL 返回错误:403 - fatal: unable to access 'https://git-codecommit.eu-west-1.amazonaws.com/v1/repos/myrepo/': The requested URL returned error: 403 致命:无法访问“https://git-codecommit.us-east-1.amazonaws.com/v1/repos/lambda-pipeline-repo/”:请求的 URL 返回错误:403 - fatal: unable to access 'https://git-codecommit.us-east-1.amazonaws.com/v1/repos/lambda-pipeline-repo/': The requested URL returned error: 403 GitHub Remote:禁止致命:无法访问请求的网址返回错误:403 - GitHub Remote: forbidden fatal: unable to access the requested url returned error: 403 AWS Codecommit - 致命:无法访问:请求的 URL 返回错误:403 - AWS Codecommit - fatal: unable to access : The requested URL returned error: 403 Git,致命:无法访问“https://github.com/path/to/repo.git”:gnutls_handshake() 失败:pull 函数出错 - Git, fatal: unable to access 'https://github.com/path/to/repo.git': gnutls_handshake() failed: Error in the pull function 请求的 URL 返回错误:403 Forbidden while accessing github.com - The requested URL returned error: 403 Forbidden while accessing github.com
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM