【git push 报错】fatal: unable to access……

一、问题

remote: Permission to testGit/test_album.git denied to test_name.
fatal: unable to access ‘https://github.com/test_name/test_album.git/’: The requested URL returned error: 403

二、最佳解决方案

  1. 修改本地仓库下的
    vim .git/config文件
  2. 修改内容
    [remote “origin”]
    原:url = https://github.com/test_name/test_album.git
    修改为:url = https://[email protected]/test_name/test_album.git

补充:

还可以生成密钥后来配置github 的deploykey解决该问题


發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章