git 提示error setting certificate verify locations 解决方案


问题:使用git extension 拉取或者push代码,提示

"C:\Program Files\Git\bin\git.exe" pull --progress "origin" +refs/heads/zjw
fatal: unable to access 'https://github.com/**/': error setting certificate verify locations:

CAfile: C:/Program Files/Git/mingw64/libexec/ssl/certs/ca-bundle.crt
CApath: none
Done

Press Enter or Esc to close console...

这是因为git 提交代码时需要安全认证,可以通过以下方法设置,取消验证

解决:

找到 git的config 配置文件,路径应该在 
C:\ProgramData\Git\config ,添加下面两行

[http]
    sslVerify = false
    sslCAinfo = /bin/curl-ca-bundle.crt

保存后,再提交代码就可以了。


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM