Yesterday I want to install a git, and press the PORT command on Pro git.
$ sudo port install git-core +svn +doc +bash_completion +gitweb
We need to install ten so-called dependencies of OSX, such as SSL, which are not fast and finally gave up the redundant package management method.
Uninstall macports
$ sudo port -f uninstall installed$ sudo rm -rf / /opt/local / /Applications/DarwinPorts / /Applications/MacPorts / /Library/LaunchDaemons/org.macports.* / /Library/Receipts/DarwinPorts*.pkg / /Library/Receipts/MacPorts*.pkg / /Library/StartupItems/DarwinPortsStartup / /Library/Tcl/darwinports1.0 / /Library/Tcl/macports1.0 / ~/.macports$ sudo pkgutil --forget org.macports.macports
Homebrew is filled with various comments on the Internet and will not repeat them any more.
Install
$ ruby -e "$(curl -fsS http://gist.github.com/raw/323731/install_homebrew.rb)"
Common commands
$ brew --cache
The cache directory is displayed. The downloaded source code is put here.
$ brew install --use-llvm git
Install, -- use-llvm use llvm for compilation
$ brew info
List the current installation information, such as how many packages are installed and how much space is occupied.
$ brew info emacs
List the package information. For example, emacs prompts you to append the -- cocoa parameter and compile it as a GUI program.
$ brew remove emacs
Delete
$ brew prune
Clear useless link files in/usr/local/bin
$ brew list
List all installed packages
$ brew list emacs
List the files installed by Emacs
$ brew home
Open homebrew's project Homepage
$ brew home git
Open the GIT Homepage