Mac 安裝Homebrew


brew 全稱Homebrew  是Mac OSX上的軟件包管理工具,最近如要安裝RabbitMq,但是官網強烈建議使用brew安裝,所以便有了這篇簡易隨筆。

1.安裝命令

ruby -e "$(curl --insecure -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

2.卸載命令

輸入密碼后會開始下載homebrew,如果此時網速不穩定可能會出現錯誤提示:curl: (35) Server aborted the SSL handshake。

此時需要執行卸載操作,輸入如下命令進行卸載:

ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/uninstall)"

卸載完成后再次嘗試安裝。

3.安裝完成后

通過brew命令就可以測試brew安裝完成了

HEAD is now at e57da60 Merge pull request #3548 from sjackman/x11
==> Downloading https://homebrew.bintray.com/bottles-portable/portable-ruby-2.3.3.leopard_64.bottle.1.tar.gz
######################################################################## 100.0%
==> Pouring portable-ruby-2.3.3.leopard_64.bottle.1.tar.gz
==> Tapping homebrew/core
Cloning into '/usr/local/Homebrew/Library/Taps/homebrew/homebrew-core'...
remote: Counting objects: 4654, done.
remote: Compressing objects: 100% (4432/4432), done.
remote: Total 4654 (delta 36), reused 319 (delta 10), pack-reused 0
Receiving objects: 100% (4654/4654), 3.84 MiB | 56.00 KiB/s, done.
Resolving deltas: 100% (36/36), done.
Checking connectivity... done.
Tapped 4426 formulae (4,700 files, 12.0MB)
==> Cleaning up /Library/Caches/Homebrew...
==> Migrating /Library/Caches/Homebrew to /Users/zhangli/Library/Caches/Homebrew
==> Deleting /Library/Caches/Homebrew...
Already up-to-date.
==> Installation successful!

==> Homebrew has enabled anonymous aggregate user behaviour analytics.
Read the analytics documentation (and how to opt-out) here:
  https://docs.brew.sh/Analytics.html

==> Next steps:
- Run `brew help` to get started
- Further documentation: 
    https://docs.brew.sh
MochushiledeMBP:~ zhangli$ brew
Example usage:
  brew search [TEXT|/REGEX/]
  brew (info|home|options) [FORMULA...]
  brew install FORMULA...
  brew update
  brew upgrade [FORMULA...]
  brew uninstall FORMULA...
  brew list [FORMULA...]

Troubleshooting:
  brew config
  brew doctor
  brew install -vd FORMULA

Developers:
  brew create [URL [--no-fetch]]
  brew edit [FORMULA...]
  https://docs.brew.sh/Formula-Cookbook.html

Further help:
  man brew
  brew help [COMMAND]
  brew home

 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM