Setting up a Mac

Optional: Reinstall macOS

Reinstall macOS using this guide: https://support.apple.com/en-gb/guide/mac-help/mchlp1599/mac

This includes a lot of free apps I use on my Mac. I have a comprehensive list of these in Github and Google Sheets.

i. Preparation

Homebrew has a built in bundle feature which allows you to automate the installation of multiple packages, both from brew, and also from the Mac App Store using mas. I used to separate these out, but this is a much simpler process.

This uses a Brewfile which is a text file which lists all the packages which you want to install. A Brewfile can have the following types of line: tap - A Homebrew tap to add brew - A Homebrew formula to install cask - A Homebrew cask to install mas - A Mac App Store ID to install vscode - A Visual Studio Code extension to install whalebrew - Docker images ditributed using the whalebrew package manager

I currently do not use whalebrew. I also like to manually install my vscode extensions, so I do not include these in my Brewfile.

It is important to note that to use the mas command, you need to have installed the mas package, so you need to include this in your Brewfile above any mas lines.

A very basic Brewfile might look like this:

tap 'homebrew/cask'
brew 'mas'
mas "Xcode", id: 497799835

In this example, the homebrew/cask tap is added, the mas package is installed, and the Xcode app is installed from the Mac App Store.

If you have a current installation of Homebrew on an existing Mac that you want to replicate on another Mac, you can create a Brewfile by running the following command:

brew bundle dump

You can edit this Brewfile using TextEdit.


1 - Install apps