What is brew? Homebrew OS X's indispensable suite manager.
Brew is a new Mac user need to understand the necessary command, it is under the MAC package management software, similar to the CentOS under the Yum, Ubuntu under the apt-get, eliminating their own manual compile installation inconvenient.
Most of the time as a user more or less a bit of cleanliness, do not want the system to turn to junk software, brew can solve this problem.
Homebrew installs the suite to a stand-alone directory and links the files to/usr/local, all files are installed in a predefined directory, so you don't have to worry about the Homebrew installation location.
Brew Installation Method
You need to install command line Tools prior to the brew installation, that is, the ability to perform commands such as GCC.
Brew installation requires only one command
Ruby-e "$ (curl-fssl https://raw.githubusercontent.com/Homebrew/install/master/install)"
The screen will output:
==> This script would install:
/usr/local/bin/brew
/usr/local/library/...
/usr/local/share/man/man1/brew.1
==> The following directories would be made group writable:
/usr/local/.
/usr/local/bin
/usr/local/etc
/usr/local/lib
==> The following directories would have their group set to admin:
/usr/local/.
/usr/local/bin
/usr/local/etc
/usr/local/lib
Press ENTER to continue
==>/usr/bin/sudo/bin/chmod g+rwx/usr/local/. /usr/local/bin/usr/local/etc/usr/local/lib
Password:
You will first ask if you agree to modify the directory permissions. After agreeing to enter the sudo password, the entire process will be completed automatically.
The installation process lists the changes to each step and asks if you agree, primarily by modifying the directory permissions.
These directories are the locations of future installation software so that you don't have to sudo, you can install it directly without the password.
How brew is used
Homebrew's executable command is brew, and its basic usage is as follows (take wget as an example).
Find Packages
Brew Search Wget
Installing packages
Brew Install wget
To list installed packages
Brew List
removing packages
Brew Remove wget
View package Information
Brew Info wget
List dependencies for packages
Brew Deps wget
Update Brew
Brew Update
List obsolete packages (installed but not up to date)
Brew outdated
Update obsolete packages (all or specified)
Brew Upgrade
Or
Brew Upgrade wget
Of course, if you want to install the software homebrew, also support their own customization, the process is not so simple, here is not introduced, interested can go to the official website to view the document