一、MAC安装brew(先翻墙)
- 命令
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
二、安装过程
==> This script will install:
/usr/local/bin/brew
/usr/local/Library/...
/usr/local/share/man/man1/brew.1
==> The following directories will be made group writable:
/usr/local/.
/usr/local/bin
/usr/local/lib
/usr/local/sbin
==> The following directories will have their owner set to leoiceo:
/usr/local/.
/usr/local/bin
/usr/local/lib
/usr/local/sbin
==> The following directories will have their group set to admin:
/usr/local/.
/usr/local/bin
/usr/local/lib
/usr/local/sbin
Press RETURN to continue or any other key to abort
==> /usr/bin/sudo /bin/chmod g+rwx /usr/local/. /usr/local/bin /usr/local/lib /usr/local/sbin
==> /usr/bin/sudo /usr/sbin/chown leoiceo /usr/local/. /usr/local/bin /usr/local/lib /usr/local/sbin
==> /usr/bin/sudo /usr/bin/chgrp admin /usr/local/. /usr/local/bin /usr/local/lib /usr/local/sbin
==> /usr/bin/sudo /bin/mkdir /Library/Caches/Homebrew
==> /usr/bin/sudo /bin/chmod g+rwx /Library/Caches/Homebrew
==> /usr/bin/sudo /usr/sbin/chown leoiceo /Library/Caches/Homebrew
==> Downloading and installing Homebrew...
remote: Counting objects: 4085, done.
remote: Compressing objects: 100% (3933/3933), done.
remote: Total 4085 (delta 34), reused 1775 (delta 19), pack-reused 0
Receiving objects: 100% (4085/4085), 3.36 MiB | 49.00 KiB/s, done.
Resolving deltas: 100% (34/34), done.
From https://github.com/Homebrew/homebrew
* [new branch] master -> origin/master
HEAD is now at e573061 portmidi: update 217 bottle.
==> Installation successful!
==> Next steps
Run `brew help` to get started
三、使用说明
leoiceo: ~$brew help
Example usage:
brew [info | home | options ] [FORMULA...]
brew install FORMULA...
brew uninstall FORMULA...
brew search [foo]
brew list [FORMULA...]
brew update
brew upgrade [FORMULA...]
brew pin/unpin [FORMULA...]
Troubleshooting:
brew doctor
brew install -vd FORMULA
brew [--env | config]
Brewing:
brew create [URL [--no-fetch]]
brew edit [FORMULA...]
https://github.com/Homebrew/homebrew/blob/master/share/doc/homebrew/Formula-Cookbook.md
Further help:
man brew
brew home