解决github push错误The requested URL returned error: 403 Forbidden while accessing

git push 之后 出现这样一个错误  

  1. error: The requested URL returned error: 403 Forbidden while accessing https://github.com/wangz/future.git/info/refs  

这个可能是因为 git 版本的问题 

解决办法是:

在 克隆的文件夹下  的终端中 输入 命令  vim .git/config

然后 就会出现一个窗口 , 在其中修改 url , arenouba 是github的用户名

  1. [remote "origin"]  
  2.     url = https://github.com/arenouba/example.git  
  3. [remote "origin"]  
  4. url = https://arenouba@github.com/wangz/example.git
  5. 然后再次 git push 输入一次密码就行了
原文地址:https://www.cnblogs.com/arenouba/p/5440823.html