brew安装coreutils错误10.12.6 OSX

时间:2017-11-02 01:38:03

标签: macos homebrew gnu-coreutils

在OSX安装错误中,

brew install coreutils

Error: coreutils: /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core/Formula/coreutils.rb:73: syntax error, unexpected << def caveats; <<~EOS

/usr/local/Homebrew/Library/Taps/homebrew/homebrew-core/Formula/coreutils.rb:77: syntax error, unexpected tIDENTIFIER, expecting keyword_end
can add a "gnubin" directory to your PATH from your bashrc like:

/usr/local/Homebrew/Library/Taps/homebrew/homebrew-core/Formula/coreutils.rb:77: syntax error, unexpected ':', expecting keyword_end
/usr/local/Homebrew/Library/Taps/homebrew/homebrew-core/Formula/coreutils.rb:79: dynamic constant assignment
    PATH="#{opt_libexec}/gnubin:$PATH"
         ^
/usr/local/Homebrew/Library/Taps/homebrew/homebrew-core/Formula/coreutils.rb:81: dynamic constant assignment
Additionally, you can access their man pag...
             ^
/usr/local/Homebrew/Library/Taps/homebrew/homebrew-core/Formula/coreutils.rb:81: syntax error, unexpected tIDENTIFIER, expecting keyword_do or '{' or '('
Additionally, you can access their man pages with ...
                     ^
/usr/local/Homebrew/Library/Taps/homebrew/homebrew-core/Formula/coreutils.rb:82: syntax error, unexpected tIDENTIFIER, expecting keyword_end
the "gnuman" directory to your MANPATH from your bashrc as well:
                      ^
/usr/local/Homebrew/Library/Taps/homebrew/homebrew-core/Formula/coreutils.rb:82: syntax error, unexpected ':', expecting keyword_end
/usr/local/Homebrew/Library/Taps/homebrew/homebrew-core/Formula/coreutils.rb:84: dynamic constant assignment
    MANPATH="#{opt_libexec}/gnuman:$MANPATH"`

是什么原因?   请帮助我谢谢

1 个答案:

答案 0 :(得分:5)

GitHub上有一个关于此的问题:https://github.com/Homebrew/brew/issues/3353

根据该讨论,这解决了错误:

rm -rf /usr/local/Homebrew/.git
brew update
brew config

我自己没有测试过。