Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save dmrty/dc5dd9db503702ec1a7abfe15f3a4897 to your computer and use it in GitHub Desktop.
Save dmrty/dc5dd9db503702ec1a7abfe15f3a4897 to your computer and use it in GitHub Desktop.
macOS 10.12 Sierra Setup

macOS 10.12 Sierra Setup

Custom recipe to get macOS 10.12 Sierra running from scratch, setup applications and developer environment. T

I use this gist to keep track of the important software and steps required to have a functioning system after a semi-annual fresh install.

Install OS X

  • Make backup
  • Download Sierra installer
  • Format USB Stick, name it Sierra
  • Copy the Sierra installer onto the stick
sudo /Applications/Install\ macOS\ Sierra.app/Contents/Resources/createinstallmedia --volume /Volumes/Sierra --applicationpath /Applications/Install\ macOS\ Sierra.app --nointeraction

Install Software

The software selected is software that is "tried and true" --- software I need after any fresh install. I often install other software not listed here, but is handled in a case-by-case basis.

Prerequisites

Homebrew

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

Mac App Store Command Line Tools

The mas command by argon is a handy tool to interact with the App Store without needing to point and click, search, and otherwise need manual intervention. This lets us install the next batch of software very quickly using Terminal.

Now that Homebrew is installed, it's easy to get mas:

brew install mas

Then signin to the Mac App Store for the first time:

mas signin YOUR@EMAIL.COM

Install binaries from a Brewfile (apps from App Store using mas, apps from Cask)

Retrieve Brewfile

curl -o Brewfile https://gist.githubusercontent.com/gillesdemarty/dc5dd9db503702ec1a7abfe15f3a4897/raw/b176f434ae7f52b0b8e9b5f6593406837aaaa1a0/2-macOS-10.12-sierra-setup-brewfile

Edit Brewfile for last minute changes

You may wish to add or remove a few App Store or Cask items before initiating Homebrew to install all of the applications. If you wish to review these now you may examine the Brewfile now.

Install apps

brew bundle install

This will take some time, especially if you have a slow internet connection and because Xcode is huge. But it's faster than you having to search the App Store app and click to install for each of these!

Shell

Install custom .dotfiles

git clone git@github.com:dmrty/.dotfiles.git ~/.dotfiles
~/.dotfiles/install.sh

Update .bash_profile

echo 'source ~/.dotfiles/base.sh' >> ~/.bash_profile

OS X Preferences

#Store screenshots in subfolder on desktop
mkdir ~/Screenshots
defaults write com.apple.screencapture location ~/Screenshots

Set hostname

sudo scutil --set HostName mbp-gilles

#Git

Setup Github

ssh-keygen -t rsa -C "gilles@dmrty.fr"

# Copy ssh key to github.com
subl ~/.ssh/id_rsa.pub
open https://github.com/settings/keys

# Test connection
ssh -T git@github.com

# Set git config values
git config --global user.name "Gilles Demarty"
git config --global user.email "gilles@dmrty.fr"
git config --global github.user dmrty
git config --global github.token your_token_here

git config --global core.editor "subl -w"
git config --global color.ui true

Edit ~/.ssh/config

Host * (asterisk for all hosts or add specific host)
  AddKeysToAgent yes
  UseKeychain yes
  IdentityFile ~/.ssh/id_rsa
tap 'caskroom/cask'
tap 'homebrew/bundle'
tap 'homebrew/core'
tap 'homebrew/services'
brew 'git'
brew 'git-flow'
brew 'mas'
brew 'mysql'
cask 'adobe-creative-cloud'
cask 'atom'
cask 'dropbox'
cask 'firefox'
cask 'github-desktop'
cask 'google-chrome'
cask 'iterm2'
cask 'sketch'
cask 'skype'
mas 'iMovie', id: 408981434
mas 'Pages', id: 409201541
mas 'Slack', id: 803453959
mas 'Numbers', id: 409203825
mas 'Better', id: 1121192229
mas 'Twitter', id: 409789998
mas '1Password', id: 443987910
mas 'OmniFocus', id: 867299399
mas 'Polymail', id: 1134717305
mas 'Airmail 3', id: 918858936
mas 'Keynote', id: 409183694
mas 'Harvest', id: 506189836
mas 'Telegram', id: 747648890
@franktopel
Copy link

On my system (Mac OSX Sierra, German) applying

Set a blazingly fast keyboard repeat rate

defaults write NSGlobalDomain KeyRepeat -int 0.02

Set a shorter Delay until key repeat

defaults write NSGlobalDomain InitialKeyRepeat -int 12

led to keys not repeating at all.

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