以前,我更改了 Github 帐户用户名。我创建了一个新的Repo并尝试使用git推送它。但它返回错误:
remote: Permission to <current-username>/<repo>.git denied to <previous-username>.
fatal: unable to access 'https://github.com/<current-username>/<repo>.git/':
The requested URL returned error: 403
任何人都有解决这个问题的方法吗?感谢
答案 0 :(得分:1)
您应该将您的SSH密钥更新为git local上的用户名甚至更新。
https://help.github.com/articles/setting-your-username-in-git/
https://help.github.com/articles/generating-a-new-ssh-key-and-adding-it-to-the-ssh-agent/