Mac brew update出问题

问题

在使用brew 安装软件时出现以下问题,最后通过更新homebrew镜像源,brew update成功后,安装软件成功,以下针对这些问题做些记录。
一、Warning: Calling sha256 "digest" => :tag in a bottle block is deprecated!
二、LibreSSL SSL_connect: SSL_ERROR_SYSCALL in connection to github.com:443

解决方案

针对问题一

git -C /usr/local/Homebrew/Library/Taps/homebrew/homebrew-cask fetch --unshallow
brew style --fix /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core/Formula

针对问题二

执行brew update 出现LibreSSL SSL_connect: SSL_ERROR_SYSCALL in connection to github.com:443问题

解决:更换brew源

git -C “$(brew --repo)” remote set-url origin https://mirrors.ustc.edu.cn/brew.git

git -C “$(brew --repo homebrew/core)” remote set-url origin https://mirrors.ustc.edu.cn/homebrew-core.git

git -C “$(brew --repo homebrew/cask)” remote set-url origin https://mirrors.ustc.edu.cn/homebrew-cask.git

if [ $SHELL = “/bin/bash” ] # 如果你的是bash
then
echo ‘export HOMEBREW_BOTTLE_DOMAIN=https://mirrors.ustc.edu.cn/homebrew-bottles/’ >> ~/.bash_profile
source ~/.bash_profile
elif [ $SHELL = “/bin/zsh” ] # 如果用的shell 是zsh 的话
then
echo ‘export HOMEBREW_BOTTLE_DOMAIN=https://mirrors.ustc.edu.cn/homebrew-bottles/’ >> ~/.zshrc
source ~/.zshrc
fi

brew update

猜你喜欢

转载自blog.csdn.net/yunlilang/article/details/117019505