又一个repo之前是私有的,在setting中make public后,push的时候报错,Permission denied 如下:

解决方法:
查看远端项目地址
$ git remote -v
origin https://github.com/Waldenz/JupyterSrc.git (fetch)
origin https://github.com/Waldenz/JupyterSrc.git (push)
删除远端项目地址
$ git remote rm origin
重新添加地址
$ git remote add origin git@github.com:Waldenz/JupyterSrc.git
本文介绍了一种解决GitHub上从私有仓库转换为公开仓库后,遇到的Push权限拒绝错误的方法。通过修改远程仓库地址,使用SSH密钥而非HTTPS,成功解决了权限问题。
316

被折叠的 条评论
为什么被折叠?



