MacBook setup for a ML Engineer Using Homebrew

Niels van den Berg
4 min readJan 12, 2022

Recently I needed to reinstall my MacBook, which is, unfortunately, also part of the job. To speed up the process and help future me, I decided to write down all the steps and share them with you.

In this blog post, I show how to use Homebrew to reinstall (almost) all my favorite software and tools that I use as an ML engineer. First I dive into developer tools, thereafter I focus on more general software. Hopefully, you find some interesting ones that benefit you in your job as well!

Another type of home brew — photo by Andreas Palmer on Unsplash

Developer tools

Eight tools and programs that I use daily while solving problems with Python.

Oh my zsh

Zsh is the default shell in macOS. Oh my Zsh provides some nice plugins and features to spice up the terminal. For instance, it shows on what Git branch you are working and it has color schemes.

sh -c “$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"

Homebrew

The missing package manager for macOS (according to their own words). It allows you to install software via the command line, which is faster than downloading and installing from websites. I will use it often in the recommendations below. Install Homebrew via the terminal as follows — be ready to type your password a dozen times:

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

I needed to run the following command to successfully finalize the installation: sudo chown -R $(whoami) $(brew-prefix)/* and rerun the previous command again.

Git

All projects require Git. Although macOS brings its own version of Git, I prefer to install and manage it myself.

brew install git

Afterward, add it to the Path so it can be found by your terminal by adding this line to your Zsh configuration in the file ~/.zshrc: export PATH=/usr/local/bin/git:$PATH

Sourcetree

I am the kind of developer that still needs a GUI from time to time to get an overview of all Git branches. For that I use Sourcetree. The nice thing here is that it has a dark mode. After installing (and registering…), set in Preferences the Git version it uses to the system one (the one we just installed), instead of the Sourcetree embedded one.

brew install sourcetree

Miniconda and Mamba

Miniconda is a lightweight version of Conda, a Python package and environment system. If you prefer to have a GUI for your package manager, switch to Anaconda.

Install via brew install --cask miniconda, afterwards configure it to work with the macOS zsh: conda init zsh

Actually, I prefer Mamba over Miniconda, as it is much faster: it downloads and installs your packages in parallel. It can be installed via Conda (that’s why we need Conda in the first place).

conda install mamba -n base -c conda-forge

and afterwards do a mamba init.

Double Commander

Double Commander is an alternative for Finder, and is based on Total Commander for Windows. I don’t like Finder for many reasons, for example, you cannot quit it (but read here how you can) and the lack of shortcuts.

In Double Commander, you have two file windows next to each other, which allows for easy movement of files and comparisons of directories. Next, there are many shortcuts hidden under the function keys.

After installation, I needed to fix the path to the terminal (the function key F9 starts a terminal in the current directory) to System/Applications/Utilities/Terminal.app. Also, I decrease the font size and icon size; and change the color of Background 2 to light grey. Unfortunately, only dark mode is lacking…

brew install double-commander

DBeaver

For all database interactions, I use DBeaver, which connects to almost all databases and data warehouses, and does come with a dark mode. My Dutch colleagues often call it John DBeaver — here’s why:

John DBeaver in action
brew install --cask dbeaver-community

VSCodium

My preferred IDE is Visual Studio Code, I prefer it over Pycharm because of all the nice plugins — I am writing a blog post on that one as well. VSCodium is the open-source version of VSCode, without Telemetry and Tracking by Microsoft.

brew install --cask vscodium

Docker

Docker Desktop requires a paid subscription if you’re working for a large company like me. If you don’t want to go that route, you could install Docker via Homebrew instead using the approach as discussed in this blog post.

Other software

Some other tools and packages, can I call them helpers? Not directly related to developing applications, but they do make my life a lot easier.

Hidden bar

Clean up the macOS menu bar with Hidden bar.

brew install hiddenbar

Unclack

Be a nice colleague and auto-mute yourself when you are typing on your mechanical keyboard by installing Unclack.

brew install unclack

Notion

Notion is the tool I use to make notes, I prefer it over Microsoft’s Onenote and it can be used both on Mac and on Windows.

brew install --cask notion

Todoist

Todoist is the tool I use to keep track of all my tasks, so my mind doesn’t need to and no longer reminds me at the most random times of some random task.

brew install --cask todoist

Magnet

Unfortunately, this last one doesn’t come for free and cannot be installed via Brew, but I really like it. I use Magnet to arrange my open windows side by side (on Windows this is built-in functionality actually…).

--

--

Niels van den Berg

MLOps specialist working for Deloitte. I assist clients with deploying ML applications to Production. Home automation enthusiast in my spare time.