官網:http://brew.sh/java
brew是Mac中安裝軟件的神器,必定要安裝一個,必定要,必定要。git
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
驗證brew安裝是否成功github
➜ brew -v Homebrew 0.9.5 (git revision f0645; last commit 2015-11-24)
➜ brew install tree
等待安裝結束後,就結束了。json
控制檯進入目錄,直接輸入tree,便可展現tree結果:樹型結構、目錄下全部的文件夾數、目錄下文件夾ruby
➜ tree . ├── env │ └── default │ ├── default.properties │ └── java.properties ├── libs ├── manifest.json ├── specs │ └── hello_world.spec └── src └── test └── java └── StepImplementation.java 7 directories, 5 files