使用brew 环境要求, 已经安装ruby, git 这里假设环境已 OK,只需要在命令行终端输入一下命令,即开始进行安装brew.

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

使用 brew config 查看自己的环境, 我的环境配置如下

HOMEBREW_VERSION: 1.4.1-11-g583b61f
ORIGIN: https://github.com/Homebrew/brew
HEAD: 583b61fd324643f15bb8017a6b652afbbbfe7cbc
Last commit: 2 days ago
Core tap ORIGIN: https://github.com/Homebrew/homebrew-core
Core tap HEAD: e1f84c3a98b856e0868734cefeb19047d4e2a3f7
Core tap last commit: 14 hours ago
HOMEBREW_PREFIX: /usr/local
HOMEBREW_DEV_CMD_RUN: 1
CPU: octa-core 64-bit haswell
Homebrew Ruby: 2.3.3 => /usr/local/Homebrew/Library/Homebrew/vendor/portable-ruby/2.3.3/bin/ruby
Clang: 9.0 build 900
Git: 2.14.3 => /Applications/Xcode.app/Contents/Developer/usr/bin/git
Curl: 7.54.0 => /usr/bin/curl
Perl: /usr/bin/perl
Python: /usr/local/opt/python/libexec/bin/python => /usr/local/Cellar/python/2.7.14/Frameworks/Python.framework/Versions/2.7/bin/python2.7
Ruby: /Users/lena/.rvm/rubies/ruby-2.4.0/bin/ruby
Java: 1.8.0_144, 1.8.0_121, 1.8.0_74
macOS: 10.13.2-x86_64
Xcode: 9.2
CLT: 9.2.0.0.1.1510905681
X11: 2.7.11 => /opt/X11
  1. 安装需要的软件
# 安装 mysql 为例
brew install mysql

# 按照提示进行设置
mysql_secure_installation

# 起停
mysql.server  {start|stop|restart|reload|force-reload|status}

# 设置 my.cnf
/usr/local/etc/my.cnf

# 查看软件的详细信息
brew info mysql

# 查看软件的官网
brew home mysql

# 查看软件安装选项
brew options mysql

# 升级软件
brew upgrade mysql

# 卸载软件
brew uninstall mysql

# 搜索软件
brew search mysql

  1. 安装 app brew cask
# 安装 sequel-pro 数据库管理软件为例
brew cask install sequel-pro
brew cask info sequel-pro
brew cask home sequel-pro
brew cask uninstall sequel-pro
......

更多的参数命令可以查看相关的帮助文档,如下

brew cask

Commands:

    --version              displays the Homebrew-Cask version
    audit                  verifies installability of Casks
    cat                    dump raw source of the given Cask to the standard output
    cleanup                cleans up cached downloads and tracker symlinks
    create                 creates the given Cask and opens it in an editor
    doctor                 checks for configuration issues
    edit                   edits the given Cask
    fetch                  downloads remote application files to local cache
    home                   opens the homepage of the given Cask
    info                   displays information about the given Cask
    install                installs the given Cask
    list                   with no args, lists installed Casks; given installed Casks, lists staged files
    outdated               list the outdated installed Casks
    reinstall              reinstalls the given Cask
    search                 searches all known Casks
    style                  checks Cask style using RuboCop
    uninstall              uninstalls the given Cask
    upgrade                upgrades all outdated casks
    zap                    zaps all files associated with the given Cask

附录电脑已安装的软件:

gitbook-editor GitBook-Editor
postman		postman
youdaodict	有道词典
youdaonote	有道云笔记
neteasemusic  网易云音乐
jietu			QQ截图
aria2gui		下载工具
boostnote	笔记
cheatsheet	快捷键预览
cyberduck	ftp上传工具
easyfind		快速查找文件
popclip		
tickeys		键盘声音
wechatwebdevtools  微信开发者工具
thunder		迅雷软件
firefox		火狐浏览器
google-chrome	chrome 浏览器
appium		移动端自动测试框架
baidunetdisk 	百度网盘
shadowsocksx
sequel-pro	数据库管理
the-unarchiver 非常好用的解压工具
qq			腾讯 qq
qqlive		腾讯视频
iina			视频播放器
youku		优酷视频
licecap		屏幕截图成动态图片
ocrkit		图片转为文字-试用14天
axure-rp		流程图工具收费
mweb		markdown 工具收费
screenflow	视频编辑和屏幕录制 收费
rstudio		编辑器 Rstudio
zend-studio	zend	
android-studio
goland		Golang 开发工具
phpstorm		PHP 开发工具
pycharm		Python 开发工具
intellij-idea	 Java 开发工具
clion			使用30天
sublime-text	sublime 编辑器
charles		抓包工具

继续阅读关于 的文章



Fork me on GitHub