Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save suzannealdrich/bf145e46d48c6d74c775951a939ec9f5 to your computer and use it in GitHub Desktop.
Save suzannealdrich/bf145e46d48c6d74c775951a939ec9f5 to your computer and use it in GitHub Desktop.
macOS 10.15 Catalina Mostly-Automated Setup

macOS 10.15 Catalina Setup

An easy to refer to document for setting up macOS 10.15 Catalina.

Previous Setup Gists

My previous macOS / OSX setup gists:

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

System Config Files

Files from my personal system-config repository on GitHub. There are some useful scripts and configs that make this process quick. This contains a Brewfile, for example.

git clone https://github.com/suzannealdrich/system-config ~/.system-config

Homebrew

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

Xcode Command Line Tools

During install of Homebrew, the script will kindly detect that you have not yet installed Xcode Command Line Tools, and pop up a dialog asking if you want to install it. Yes, you do. I defer to install the full Xcode until later since the download takes longer and I want to keep moving forward. For now, just the Xcode Command Line Tools.

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 (if you are already signed in, then it will tell you):

mas signin [email protected]

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

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 fork the system-config repo and edit the Brewfile (~/.system-config/Brewfile) now.

Install apps

brew bundle --file=~/.system-config/Brewfile

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!

Post-Installation

Keybase FS Fix

In order to get Keybase file system Fuse integration working with macOS Catalina, you may need to reinstall the cask to access the Gatekeeper prompts to allow this downloaded application to work properly: keybase/client#17796

tap "cloudflare/cloudflare"
tap "homebrew/bundle"
tap "homebrew/cask"
tap "homebrew/cask-fonts"
tap "homebrew/cask-versions"
tap "homebrew/core"
brew "awscli"
brew "cask"
brew "composer"
brew "curl"
brew "docker", link: false
brew "gist"
brew "git"
brew "git-flow"
brew "gnupg", link: false
brew "go"
brew "hugo"
brew "jq"
brew "lynx"
brew "mas"
brew "node"
brew "roswell"
brew "starship"
brew "tree"
brew "wget"
brew "cloudflare/cloudflare/cloudflared"
cask "discord"
cask "docker"
cask "docker-toolbox"
cask "dropbox"
cask "firefox"
cask "font-hack-nerd-font"
cask "google-chrome"
cask "google-cloud-sdk"
cask "gpg-suite"
cask "iterm2"
cask "keybase"
cask "minecraft"
cask "notion"
cask "quik"
cask "rectangle"
cask "slack"
cask "spotify"
cask "virtualbox"
cask "visual-studio-code"
cask "zoom"
mas "1Password 7", id: 1333542190
mas "GarageBand", id: 682658836
mas "iMovie", id: 408981434
mas "Keynote", id: 409183694
mas "Kindle", id: 405399194
mas "Numbers", id: 409203825
mas "Pages", id: 409201541
mas "Xcode", id: 497799835
#!/usr/bin/sh
## macOS Preferences
# Set a blazingly fast keyboard repeat rate
defaults write NSGlobalDomain KeyRepeat -int 1
# Set a shorter Delay until key repeat
defaults write NSGlobalDomain InitialKeyRepeat -int 10
# Add a context menu item for showing the Web Inspector in web views
defaults write NSGlobalDomain WebKitDeveloperExtras -bool true
# Show the ~/Library folder
chflags nohidden ~/Library
# Store screenshots in subfolder on desktop
mkdir ~/Desktop/Screenshots
defaults write com.apple.screencapture location ~/Desktop/Screenshots
## Github
ssh-keygen -t rsa -C "suzannealdrich@`hostname -s`"
# Copy public key to Github.com
# cat ~/.ssh/id_rsa.pub
# Test connection
# ssh -T [email protected]
# Git global config
git config --global user.name "Suzanne Aldrich"
git config --global user.email "[email protected]"
git config --global github.user suzannealdrich
# git config --global github.token your_token_here
git config --global user.signingkey 3747228BE9CC066E
git config --global commit.gpgsign true
git config --global core.editor "code -w"
git config --global color.ui true
git config --global core.excludesfile ~/.gitignore_global
git config --global init.defaultBranch main
#!/usr/bin/sh
# Setup ~/.zshrc
cp ~/.system-config/dotfile-zshrc ~/.zshrc
# Run ZSH so that everything intializes
zsh
# Change user shell to zsh
chsh
# PENDING
# zsh options
setopt NO_CASE_GLOB
setopt AUTO_CD
# show substituted commands in the prompt
setopt HIST_VERIFY
# enable zsh correction
# setopt CORRECT
# setopt CORRECT_ALL
# enable the default zsh completions
autoload -Uz compinit && compinit
# save command history
HISTFILE=${ZDOTDIR:-$HOME}/.zsh_history
SAVEHIST=5000
HISTSIZE=2000
# share history across multiple zsh sessions
setopt SHARE_HISTORY
# append to history
setopt APPEND_HISTORY
# adds commands as they are typed, not at shell exit
setopt INC_APPEND_HISTORY
# expire duplicates first
setopt HIST_EXPIRE_DUPS_FIRST
# do not store duplications
setopt HIST_IGNORE_DUPS
# ignore duplicates when searching
setopt HIST_FIND_NO_DUPS
# removes blank lines from history
setopt HIST_REDUCE_BLANKS
export GPG_TTY=$(tty)
# enable git completion
zstyle ':completion:*:*:git:*' script ~/.zsh/git-completion.bash
fpath=(~/.zsh $fpath)
# case insensitive path-completion
zstyle ':completion:*' matcher-list 'm:{[:lower:][:upper:]}={[:upper:][:lower:]}' 'm:{[:lower:][:upper:]}={[:upper:][:lower:]} l:|=* r:|=*' 'm:{[:lower:][:upper:]}={[:upper:][:lower:]} l:|=* r:|=*' 'm:{[:lower:][:upper:]}={[:upper:][:lower:]} l:|=* r:|=*'
# partial completion suggestions
zstyle ':completion:*' list-suffixes
zstyle ':completion:*' expand prefix suffix
# minimal aliases
alias ..='cd ..'
alias ...='cd ../..'
alias ls='ls -GwF'
alias ll='ls -alh'
# VSCode aliases
alias zshrc='code ~/.zshrc'
alias gitconfig='code ~/.gitconfig'
# add Google Cloud SDK command line tools to $PATH
source "/usr/local/Caskroom/google-cloud-sdk/latest/google-cloud-sdk/path.zsh.inc"
source "/usr/local/Caskroom/google-cloud-sdk/latest/google-cloud-sdk/completion.zsh.inc"
eval "$(starship init zsh)"
test -e /Users/suzannealdrich/.iterm2_shell_integration.zsh && source /Users/suzannealdrich/.iterm2_shell_integration.zsh || true
# OS generated files #
######################
.DS_Store
.DS_Store?
# Configuration file for the Starship prompt
# See: https://starship.rs/config/
[battery]
full_symbol = "πŸ”‹"
charging_symbol = "πŸ”Œ"
discharging_symbol = "⚑"
[[battery.display]]
threshold = 30
style = "bold red"
[character]
error_symbol = "[βœ–](bold red) "
[cmd_duration]
min_time = 10_000 # Show command duration over 10,000 milliseconds (=10 sec)
format = " took [$duration]($style)"
[directory]
truncation_length = 5
format = "[$path]($style)[$lock_symbol]($lock_style) "
[git_branch]
format = " [$symbol$branch]($style) "
symbol = "🌱 "
style = "bold yellow"
[git_commit]
commit_hash_length = 8
style = "bold white"
[git_state]
cherry_pick = "πŸ’ PICKING"
[git_status]
conflicted = "βš”οΈ "
ahead = "🏎️ πŸ’¨ Γ—${count}"
behind = "🐒 Γ—${count}"
diverged = "πŸ”± 🏎️ πŸ’¨ Γ—${ahead_count} 🐒 Γ—${behind_count}"
untracked = "πŸ›€οΈ Γ—${count}"
stashed = "πŸ“¦ "
modified = "πŸ“ Γ—${count}"
staged = "πŸ—ƒοΈ Γ—${count}"
renamed = "πŸ“› Γ—${count}"
deleted = "πŸ—‘οΈ Γ—${count}"
style = "bright-white"
format = "$all_status$ahead_behind"
[hostname]
ssh_only = false
format = "<[$hostname]($style)>"
trim_at = "-"
style = "bold dimmed white"
disabled = true
[memory_usage]
format = "$symbol[${ram}( | ${swap})]($style) "
threshold = 70
style = "bold dimmed white"
disabled = false
[package]
disabled = true
[python]
format = "[$symbol$version]($style) "
style = "bold green"
[rust]
format = "[$symbol$version]($style) "
style = "bold green"
[time]
time_format = "%T"
format = "πŸ•™ $time($style) "
style = "bright-white"
disabled = false
[username]
style_user = "bold dimmed blue"
show_always = false
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment