Git -- git push发生HTTP request failed错误
2015-10-14
问题描述
在CentOS中clone博客的Repository
cd /home git clone https://github.com/xiaofandh12/xiaofandh12.github.io.git在git push时出现HTTP request failed错误
error: The requested URL returned error: 403 Forbidden while accessing https://github.com/xiaofandh12.github.io/info/refs fatal: HTTP request failed截图如下:

解决
修改文件.git/config,将
[remote "origin"] url = https://github.com/xiaofandh12/xiaofandh12.github.io改为
[remote "origin"] url = https://xiaofandh12@github.com/xiaofandh12/xiaofandh12.github.io