Skip to content
👨🏻‍💻 Erdal

Setting up macOS for development

— macOS, Apple, Development, Terminal, Guide — 2 min read


With each release of macOS, I clean install everything on my MacBook just to be extra safe and avoid long debugging hours if there is an incompatibility. Thus this guide is about setting up your machine quickly and in a predictable way.

I'm primarily doing ML but I also set up various environnements, so feel free to be selective while reading this guide. I removed a lot of very specific things to make a good balance between development and general macOS usage.

Initial formatting steps

When everything you care about is backed up you can proceed with pressing CMD⌘+R on startup. Then go to Disk Utility, format your drive with APFS and install macOS.

Complete the initial set up with your Apple ID and choose your privacy preferences, you should now be on the desktop.

Homebrew, Zsh & Other Mac settings

Homebrew is the most popular macOS package manager, we will use it to install all our apps (except mas ones because it doesn't work anymore)

In your terminal let's copy & paste to install Homebrew

1/bin/bash -c "$(curl -fsSL"

Then let's make sure everything is up to date

1brew update && brew upgrade

You can now install your apps, or search for it on the Homebrew website

Below the "--cask" refers to graphical applications instead of formulae.

1# Note: you can install multiple apps in just one line, but this is a better visualization
2# Browsers
3brew install --cask firefox
4brew install --cask firefox-developer-edition
5brew install --cask google-chrome
6brew install --cask homebrew/cask-versions/google-chrome-dev
7# Media players
8brew install --cask iina
9brew install --cask vlc
10# File downloads and disk analyze
11brew install --cask transmission
12brew install --cask grandperspective
13# Media transcode
14brew install --cask handbrake
15# Flash images (to USB for example)
16brew install --cask balenaetcher
17# Development
18brew install --cask visual-studio-code
19brew install --cask docker
20brew install --cask local
21brew install --cask cyberduck
22brew install --cask tower
23# App cleaner
24brew install --cask appcleaner
25# Remote communication
26brew install --cask zoom
27brew install --cask discord
28# Vpn
29brew install --cask private-internet-access
30# Keyboard based window management
31brew install --cask rectangle
32# Markdown writer
33brew install --cask obsidian

Here are some formulae, make sure to understand each software that you install before trusting a random internet guide

1# Logitech Options software
2brew install homebrew/cask-drivers/logitech-options
3# Development
4brew install docker-compose
5brew install node
6brew install htop
7brew install git
8brew install tree
9# Python
10brew install pyenv
11# Shell
12brew install romkatv/powerlevel10k/powerlevel10k
13brew install zsh-autosuggestions
14brew install zsh-syntax-highlighting
15brew install zsh-history-substring-search

We can now configure Python

1pyenv install 3.9.7
2pyenv global 3.9.7
3echo -e 'if command -v pyenv 1>/dev/null 2>&1; then\n eval "$(pyenv init -)"\nfi' >> ~/.zshrc

To finish the powerlevel10k and zsh setup we need the following

1# Plugins
2echo "source $(brew --prefix)/opt/powerlevel10k/powerlevel10k.zsh-theme" >>~/.zshrc
3echo "source /usr/local/share/zsh-autosuggestions/zsh-autosuggestions.zsh" >>~/.zshrc
4echo "source /usr/local/share/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh" >>~/.zshrc
5echo "source /usr/local/share/zsh-history-substring-search/zsh-history-substring-search.zsh" >>~/.zshrc
7# Zsh tweaks
8echo -e "autoload -Uz compinit" >>~/.zshrc
9echo -e "compinit" >>~/.zshrc
10echo -e "zstyle ':completion:*' menu select" >>~/.zshrc
11# Key bindings for history searching, the order is important
12echo -e "bindkey '^[[A' history-substring-search-up" >>~/.zshrc
13echo -e "bindkey '^[[B' history-substring-search-down" >>~/.zshrc
15# Note: lines below are my personal aliases, this might disturb your workflow
16echo -e "alias c='clear'" >>~/.zshrc
17echo -e "alias rmm='rm -rf'" >>~/.zshrc
18echo -e "alias lss='ls -lah'" >>~/.zshrc
19echo -e "alias edit='code ~/.zshrc'" >>~/.zshrc
20echo -e "alias reload='source ~/.zshrc'" >>~/.zshrc

We also need to configure git basics properly

1git config --global "YOUR_EMAIL"
2git config --global "YOUR_NAME"

macOS is better with some tweaks

1# Note: There are a lot of settings that you could change, this is just a few of them that I use
2# Always show file extensions
3defaults write NSGlobalDomain AppleShowAllExtensions -bool true
4# Show status bar in Finder
5defaults write ShowStatusBar -bool true
6# Allow text selection in Quick Look
7defaults write QLEnableTextSelection -bool true
8# Disable TimeMachine prompt
9defaults write DoNotOfferNewDisksForBackup -bool true
10# This is needed to apply our changes
11killAll Finder

Finally before closing the terminal I setup powerlevel10k

1# Note: This has already been installed in the fomulae section above, this is just the install
2source ~/.zshrc

Everthing else

Once this is done I usually login into my password manager, retreive software licences, ssh keys and proceed to login to some applications like Google Chrome, Discord, etc.

Here is everything I changed in the System Preferences app

  • General > Enable Dark Mode
  • Desktop > Live wallpaper selection
  • Desktop > Screensaver > Hot Corners > Bottom Left > CMD⌘ + Display sleep
  • Dock > Enable Automatically hide
  • Siri > Disable show Siri in menu bar
  • Notifications > Disable everything or remove sounds
  • Screen Time > Enable & share across devices
  • Security > General > Require password > Immediately
  • Trackpad > More Gestures > Enable everything
  • Sharing > Setup the computer name
  • iCloud > iCloud Drive > Enable Desktop & Document
  • Keyboard > Text > Disable spelling and capitalization

Some Mac App Store apps that I use

  • 1Password (Password Manager)
  • Xcode (Code apps)
  • Amphetamine (Keep Mac awake)
  • Adguard (Safari ad disable)
  • The Unarchiver (Almost unrar for Mac)
  • Parcel (Track packages)


This was a quick look at how I install macOS, I hope this helped you in your next fresh install.

If you enjoyed this guide you can also check the previous ones about iCloud custom domains or Cloudflare argo & access on a RaspberryPi.

© 2021. All rights reserved.