error: The requested URL returned error: 401 Unauthorized while accessing
原文链接:https://blog.csdn.net/z_dianjun/article/details/50819908
在使用git pull、git push、git clone会报类似如下的错误:
error: The requested URL returned error: 401 Unauthorized while accessing https://git.oschina.net/zemo/demo.git/info/refs
fatal: HTTP request failed
一般是由于git版本的问题。
使用如下指令查看版本:
- 1
- 2
可以通过安装更高的版本解决问题。
Centos Git1.7.1升级到Git2.2.1
安装需求:
- 1
- 2
- 3
- 4
- 5
- 6
- 7
卸载Centos自带的git1.7.1:
通过git –version查看系统带的版本,Cento6.5应该自带的是git版本是1.7.1
- 1
下载git2.2.1并将git添加到环境变量中
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
查看版本号