Created: 2011-07-16 05:13
Updated: 2018-01-07 01:27

Opinions are minimal and noted.


Configuration will be handled in the next section. Feel free to ignore complaints for tools regarding .bashrc or .bash_profile, we'll handle those in the following section.

  1. Install any lingering updates. (Apple menu -> App Store -> Update)
  2. Open Terminal (command+space, "terminal", enter) and begin installing a basic dev environment:
    1. General dev utils: xcode-select --install
      • The command line option is all you need, it gives you build tools such as make, gcc, etc
      • The full xcode install is also not bad, as you can use the iOS Simulator that it comes with to test sites in mobile Safari. (Mobile Safari is different from Desktop Safari.)
    2. Homebrew (package management): /usr/bin/ruby -e "$(curl -fsSL"
      • Strong opinion: don't use MacPorts or similar. MacPorts was the only option 5-6 years ago, but Homebrew is stable for the past 3-4 years, is far less invasive, and it's easier to see what's going on under the hood.
      • Everything for Homebrew is installed under /usr/local which is a "mirror" of the higher level directory structure. So, binaries are in /usr/local/bin and config files are in /usr/local/etc. Easy to find what you need, easy to remove if something goes haywire, and easy to not overwrite system files.
    3. Update the BASH shell (OSX comes with an older version):
      1. Install: brew install bash
      2. Set as an option for use: echo "/usr/local/bin/bash" | sudo tee -a /etc/shells
      3. Change shell: chsh -s /usr/local/bin/bash
    4. Install dev tools (OSX comes with older versions):
      • Python 2.x: brew install python
      • git: brew install git
      • nginx: brew install nginx (web server)
      • fabric: pip install fabric (used for server interaction)
      • src highlight: brew install source-highlight (opion: highlights source code in terminal windows, nice to have)
      • virtualenvwrapper: pip install virtualenvwrapper (opinion: this makes working with Python virtual environments much easier, though it's not required; this doc assumes you use it)
      • aws CLI: pip install awscli (other tools exist, but this is the most complete)
      • Node Version Manager (nvm): curl -o- | bash
      • Postgres App, just install and run, PATH will be set in the next section (opinion: easier than working with brew's version)
      • P4Merge, a diff util (opinion: much better than doing merges in text files or with OSX's FileMerge util, takes into account 3-way merges, not just 2-way)
      • your editor of choice (Sublime Text is a good starting point)


  1. SSH / GIT
    • You'll need to generate a public/private keypair for SSH:
      1. ssh-keygen -t rsa -b 4096 -C "" just accept the defaults, there's no real need to use a password on this (if you do use a password, look into using the ssh-agent to reduce password prompts)
      2. Add your public key to your GitHub account. Copy it to your clipboard with pbcopy < ~/.ssh/
    • Some tools (notably Fabric) require you have an SSH config file, even if empty. Create one with: touch ~/.ssh/config
    • Set up a ~/.gitconfig. You can find mine's here which includes sections for using P4Merge as your mergetool.
  2. Bash
    • ~/.bash_profile
      • Just make this load .bashrc so we can ignore it.
      • curl -o ~/.bash_profile
    • ~/.bashrc
      • This includes some sane defaults around where to look for programs, some tool setup, and a decent command prompt. (Not highly opinionated, read the comments and change as you like just be careful with PATHs.)
      • curl -o ~/.bashrc
    • ~/.inputrc
      • Defaults to make working in Bash much nicer. Mainly better tab completion of commands/files and more. Nothing very opinionated here, but you can go crazy if, say, you prefer vi movement commands over Bash's emacs-style defaults.
      • curl -o ~/.inputrc
    • Completions (referenced in .bashrc)
      • mkdir ~/.completion
      • git (completes branchnames): curl -o ~/.completion/git.bash
      • ssh (completes server names from ~/.ssh/config): curl -o ~/.completion/ssh.bash
      • Want more?
    • Open a new Terminal window for all these changes to take effect.
  3. OS X (Sierra), copy/paste all of these commands to the terminal
Cookies help us deliver our services. By using our services, you agree to our use of cookies Learn more