Skip to content
Table of GNU-to-BSD command differences on macOS: find -printf becomes find -ls or -exec stat; sed -i needs an empty ''; date -d becomes date -v or -j -f; stat -c becomes stat -f; with a note that brew install coreutils provides gdate, gstat, and greadlink.

Why Your Linux Commands Fail on macOS (BSD vs GNU)

macOS’s command-line tools come from BSD, not the GNU coreutils that ship with most Linux distributions. They cover the same ground, but their flags don’t always match — so a command copied straight from a… 
Three verified macOS Terminal commands in a table: printf '%s' "user:pw" | base64 gives dXNlcjpwdw==; base64 -d

How to Encode and Decode Base64 on macOS

macOS ships a base64 command at /usr/bin/base64, so there’s nothing to install — it’s the FreeBSD version, which differs from the GNU one on Linux in a couple of ways worth knowing. This covers encoding… 
Homebrew install prefixes on macOS: on Apple Silicon brew --prefix returns /opt/homebrew, on Intel it returns /usr/local, above a row of common verbs install, list, upgrade, cleanup, services, bundle dump.

How to Install and Use Homebrew on macOS

Homebrew is the package manager most Mac developers use to install command-line tools and apps from the Terminal. This covers installing it, the commands you’ll use day to day, running background services, backing up your…