Skip to content

Instantly share code, notes, and snippets.

@tomysmile
Forked from DenisIzmaylov/INSTALLATION.md
Last active July 12, 2016 04:33
Show Gist options
  • Save tomysmile/6b02559e7e304612d1a8 to your computer and use it in GitHub Desktop.
Save tomysmile/6b02559e7e304612d1a8 to your computer and use it in GitHub Desktop.
Mac OS X 10.11 El Capitan: fresh install with Node.js (io.js) Developer Environment

OS X 10.11 (El Capitan) / Node.js and io.js Developer Environment

Custom recipe to get OS X 10.11 El Capitan running from scratch with useful applications and Node.js Developer environment. I use this gist to keep track of the important software and steps required to have a functioning system after fresh install.

Content

Appearance

The best fonts to code:

WebStorm

XCode & Command Line Tools

  • Download XCode 7.0 Beta or latest. Install it.
  • Then open Xcode > Preferences > Downloads > Command Line Tools or execute in Terminal:
sudo xcode-select --install
  • Select Xcode > Preferences > Locations > Command Line Tools (to avoid ld: library not found for -lgcc_s.10.5 error in working with npm).

Git

Setup

git config --global user.name "Denis Izmaylov"
git config --global user.email "example@izmy.lv"

Configure GitHub

There is 2 ways to configure keys. The first is:

  • Create new key:
ssh-keygen -t rsa -C "example@izmy.lv"
  • Copy public key:
$ pbcopy < ~/.ssh/id_rsa.pub
  • Add it to github.com

The second way was just to backup your ~/.ssh before re-install and restore it now. Be aware - private keys should have 0400 access.

Test connection

ssh -T git@github.com

Homebrew

$ ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
$ sudo chown -R $(whoami) /usr/local
$ brew update
$ brew doctor -d

NVM

First, pull the latest version of brew by running:

$ brew update && brew upgrade

Then, we install nvm:

$ brew install nvm

Finally, we need to add the following line to our .profile, .bashrc or .zshrc, to be able to run nvm from the command line:

$ echo "source $(brew --prefix nvm)/nvm.sh" >> ~/.zshrc

To test, run below:

$ nvm --version

Node.js and io.js Environment

If you are not sure which platform to use Node.js or io.js - see compatibility table. The good reason to choice io.js is React Native.

brew install node
brew install iojs

to prevent node-gyp errors (fsevents/fsevents#49)

npm install -g node-gyp-install
node-gyp-install
  • Install development tools:
npm install gulp eslint webpack node-inspector -g
  • To get installed Phantom.js and use it:
npm install phantom phantomjs -g

Electron

Build cross platform desktop apps with web technologies. Formerly known as Atom Shell.

npm install electron-prebuilt -g

Database

Redis

  • Install
$ brew install redis
  • Launch:
$ launchctl load /usr/local/opt/redis/homebrew.mxcl.redis.plist

or

$ redis-server /usr/local/etc/redis.conf
  • To have launchd start redis at login:
mkdir -p ~/Library/LaunchAgents
ln -sfv /usr/local/opt/redis/*.plist ~/Library/LaunchAgents
  • Test:
redis-cli

MongoDB

  • Try to install with Homebrew:
brew install mongodb
  • If you could not install with Homebrew try to do it manually:
curl -O https://fastdl.mongodb.org/osx/mongodb-osx-x86_64-3.0.4.tgz
tar -zxvf mongodb-osx-x86_64-3.0.4.tgz
mv mongodb-osx-x86_64-3.0.4/ /usr/local/opt/mongodb
export PATH=/usr/local/opt/mongodb/bin:$PATH
echo export PATH=/usr/local/opt/mongodb/bin:\$PATH>~/.bash_profile
chmod +x ~/.bash_profile
mkdir -p ~/data/mongodb
  • Then execute in Terminal:
sudo mongod --dbpath=$HOME/data/mongodb 

PostgreSQL

  • Install:
brew install postgres
  • Launch:
launchctl load /usr/local/opt/postgresql/homebrew.mxcl.postgresql.plist
  • To have launchd start postgres at login:
mkdir -p ~/Library/LaunchAgents
ln -sfv /usr/local/opt/postgresql/*.plist ~/Library/LaunchAgents

Tools

One of easiest ways to install apps is using Cask. So let's install it before:

brew install caskroom/cask/brew-cask

Now we can install tools by single command. Let's use it.

webp-quicklook

Open-source QuickLook plugin to generate thumbnails and previews for WebP images. Requires Mac OS X 10.7 or later.

brew cask install webpquicklook

Midnight Commander

Just install:

brew install mc

And start:

mc

Applications

  • Communication:
    • Skype
      • Use ~/Library/Application Support/Skype directory to create/restore your chat history backup
      • Disable sound notifications (Skype > Preferences > Notifications)
    • Telegram
    • Gitter
    • Slack
  • Twitter to stay turned with the best developers.
  • Productive:
    • Activity Timer provides a plain and smoothly integrated timer for your OS X status bar. Choose between time presets (3, 5, 25 or 30 minutes or custom defined intevals) which proved to be perfect intervals for all kind of activities.
  • RescueTime helps you understand your daily habits so you can focus and be more productive. Runs securely in the background. Tracks time spent on applications and websites, giving you an accurate picture of your day.

Other Installation Tracks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment