Git使用无法拉取

错误提示:

error setting certificate verify locations: CAfile: C:/Program Files/Git/mingw64/ssl/certs/ca-bundle.crt CApath: none

问题原因:

这个问题是因为git配置里crt证书的路径不正确导致的

解决办法:

  • 这个路径配置是在C:\Program Files\Git\etc\gitconfig中,应该所有人的配置都在这里

    [diff "astextplain"]
    textconv = astextplain
    [http]
    sslBackend = openssl
    sslCAInfo = D:/Git/mingw64/ssl/certs/ca-bundle.crt # 原来默认写的就是 C:/Program Files/Git/mingw64/ssl/certs/ca-bundle.crt
    [core]
    autocrlf = true
    fscache = true
    symlinks = false
    [pull]
    rebase = false
    [credential]
    helper = manager-core
    [credential "https://dev.azure.com"]
    useHttpPath = true
    [init]
    defaultBranch = master

  • ca-bundle.crt 而该文件是在git的安装目录下的,比如我的git安装路径是在D:\Git\,所以我本机的crt文件就在D:/Git/mingw64/ssl/certs/ca-bundle.crt

相关推荐
Arva .10 小时前
开发准备之日志 git
spring boot·git·后端
奇某人11 小时前
【嵌入式】【GIT】终端中文乱码修复
git
可爱的蜗牛牛11 小时前
上传本地git所有历史记录到已有远程仓库
git
idaibin13 小时前
"Git 多仓库用户身份自动切换与隐私保护指南
git·github
小何好运暴富开心幸福14 小时前
C++之日期类的实现
开发语言·c++·git·bash
im_AMBER15 小时前
Web 开发 24
前端·笔记·git·学习
银安16 小时前
Git篇(4):分支(Branch)与引用(Reference)
git
~央千澈~16 小时前
宝塔服务器面板部署安装git通过第三方应用安装收费怎么办—bash: git: command not found解决方案-优雅草卓伊凡
git
无言以对,沉默不语,随你随你。17 小时前
【解决办法】GitBash不能在任意文件夹打开
经验分享·笔记·git
stark张宇19 小时前
告别Git恐惧症!一套课程搞定Win/Mac/Linux三端配置与核心原理
git·架构·github