mac系统ruby命令安装失败,重装brew命令
最近用brew命令安装一些工具总是莫名其妙的出现问题,所以就决定卸载重装下。
先记录下碰到的一些问题吧:
1. ruby -e "$(curl -fsSL --insecure https://raw.githubusercontent.com/Homebrew/install/master/install)"
curl: (35) Server aborted the SSL handshake
-e:4: syntax error, unexpected ':', expecting end-of-input
2. ruby "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
ruby: No such file or directory -- #!/usr/bin/ruby (LoadError)
STDERR.print <<~EOS
Warning: The Ruby Homebrew installer is now deprecated and has been rewritten in Bash. Please migrate to the following command:
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"
EOS
Kernel.exec "/bin/bash", "-c", '/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"'
首先先卸载,使用命令:
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/uninstall)"
然后按照第二个问题的提示,执行命令
/bin/bash -c "$(curl -fsSL --insecure https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"
安装成功!
更多推荐
所有评论(0)