Mac OS System Setup

Build tools

Xcode Command Line Tools (gives your mac a C compiler)

Installation

xcode-select --install

Homebrew (third-party macOS package manager)

Installation

  1. In your terminal, type the following command:
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
  1. The script will explain what changes it will make and prompt you before the installation begins.

Configuration

Now you will update your PATH environment variable so your system has access to the Homebrew commands

  1. Ensure you have ~/.profile file by typing the following command in your terminal:
touch ~/.profile
  1. Add the Homebrew directory to your PATH by typing the following command in your terminal
echo "export PATH=\"/usr/local/bin:/usr/local/sbin:$PATH\"" >> ~/.profile

Required software

Python 3

Installation

brew install python3

Configuration

Add the python3 directory to your PATH so your system has access to the Python commands

echo "export PATH=\"/usr/local/opt/python3/libexec/bin:$PATH\"" >> ~/.profile

Git (distributed version control software)

Installation

brew install git

Configuration

Set your name (replace Your Name with your first and last name, e.g., Reuben Cummings)

git config --global user.name "Your Name"

Set your commit email address (replace your@email.address with your email address, e.g., reubano@gmail.com).

Note: This should be the same email address you used to signup for your GitHub account

git config --global user.email "your@email.address"

Check that both configurations have been set correctly

git config --global --list

PostgreSQL (relational database)

Installation

brew install postgresql@10

Configuration

Create a PostgreSQL user

sudo createuser -U postgres YOUR_USERNAME

Start the server

sudo pg_ctl -D /usr/local/var/postgres start

Node Version Manager (NVM)

Installation

curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.32.1/install.sh | bash

Check successful installation using

nvm --version

Configuration

List the available versions of Node.js

nvm ls-remote

Install the version of Node.js that you require

nvm install 6.9.1

Switch between installed versions of Node.js

nvm use 6.9.1