美文网首页
Homebrew安装提示"Failed during: git

Homebrew安装提示"Failed during: git

作者: 我一不小心就 | 来源:发表于2018-11-09 10:52 被阅读0次

    症状

    error: RPC failed; curl 18 transfer closed with outstanding read data remaining
    fatal: The remote end hung up unexpectedly
    fatal: early EOF
    fatal: index-pack failed
    Failed during: git fetch origin master:refs/remotes/origin/master --tags --force
    

    解决方案:

    1、将brew的install文件下载本地
          终端输入 curl -fsSL [https://raw.githubusercontent.com/Homebrew/install/master/install](https://raw.githubusercontent.com/Homebrew/install/master/install) >> brew_install
    
    
    2、修改install文件的镜像源
    终端输入 vim brew_install
    将下面两行进行修改
    #BREW_REPO = "[https://github.com/Homebrew/brew”.freeze](https://github.com/Homebrew/brew%E2%80%9D.freeze)
    #CORE_TAP_REPO = “[https://github.com/Homebrew/homebrew-core](https://github.com/Homebrew/homebrew-core)”.freeze
    替换成下面两句
    BREW_REPO = “[https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/brew.git](https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/brew.git)”.freeze
    CORE_TAP_REPO = "[https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/homebrew-core.git”.freeze](https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/homebrew-core.git%E2%80%9D.freeze)
    #就是“BREW_REPO”和“CORE_TAP_REPO”这两项,将其修改为清华的镜像
    
    3、安装
    ruby ~/brew_install
    

    参考 :https://blog.csdn.net/qq_35624642/article/details/79682979

    相关文章

      网友评论

          本文标题:Homebrew安装提示"Failed during: git

          本文链接:https://www.haomeiwen.com/subject/eqvnxqtx.html