Table of Contents

This is an updated version for El Capitan guide last year. It is basically a cheatsheet for me to finish the setup after a clean re-installation. This guide is completely third-party and is only for reference because I know developers always have their own eccentricity based on the degree of their lazy.

System Preferences

Backup

Backup all important files and folders in ~ (music and photos if necessary)

Backup all setups and packages in Sublime text (need to do only once):

$ cd ~/Library/Application\ Support/Sublime\ Text\ 3/Packages/
$ mkdir ~/Dropbox/apps/Sublime
$ mv User ~/Dropbox/apps/Sublime/
$ ln -s ~/Dropbox/apps/Sublime/User

Backup ~/.ssh/id_rsa*: the reason is that you might want to have many SSH connections depending on this. Backup the id_rsa and id_rsa.pub by using the following command:

$ cp -r ~/.ssh <your/backup/path>;

Basics

Development Environment

«««< HEAD $ cd ~/Library/Application\ Support/Sublime\ Text\ 3/Packages/ $ rm -r User $ ln -s ~/Dropbox/apps/Sublime/User $ ln -s ~/Dropbox/apps/Sublime/Colorsublime-Themes ======= - $ cd ~/Library/Application\ Support/Sublime\ Text\ 3/Packages/ - $ rm -r User - $ rm -r Colorsublime-Themes - $ ln -s ~/Dropbox/apps/Sublime/User - $ ln -s ~/Dropbox/apps/Sublime/Colorsublime-Themes

2. Install package control: `cmd+shift+p` -> install package control
3. Theme: [El-Capitan-Theme](https://github.com/iccir/El-Capitan-Theme) >>>>>>> 196bd097a583b1932da6d3d83cac0348472abaa4

Install Command Line Tools:

$ xcode-select --install

Install Homebrew:

$ ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/masterinstall)"`
$ brew update

Install Node.js

$ brew install node

Install zsh and oh-my-zsh:

$ brew install zsh
$ sh -c "$(curl -fsSL https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/mastertools/install.sh)"` `/usr/local/bin/zsh`

Install Postgres:

$ brew install postgresql

Install MySQL:

$ brew install mysql

Install Python:

$ brew install python
$ brew linkapps python

Install virtualenv:

$ pip install virtualenv

Install virtualenvwrapper:

$ pip install virtualenvwrapper
$ export WORKON_HOME=~/venvs
$ source /usr/local/bin/virtualenvwrapper.sh

Install RVM:

$ \curl -sSL https://get.rvm.io | bash -s stable

Before run:

$ source /Users/hao/.rvm/scripts/rvm

Reload:

$ rvm reload

Put the cmds into ~/.zshrc:

source $HOME/.rvm/scripts/rvm
export PATH="$PATH:$HOME/.rvm/bin"

Install Ruby:

$ rvm install ruby

Set default:

$ rvm --default use 2.3.1

Install Jekyll:

$ gem install github-pages

Setup Hammerspoon (for shortcuts)

Download. Configuration files hosted on Github.

Clone it to ~/.hammerspoon.

Other apps