EECS 298: Social Consequences of Computing

macOS command line tools

macOS comes with a Terminal and can run UNIX command-line tools directly.

When you see $ in this tutorial, you should type into your shell the command that comes after the $.

Open terminal

Open the Terminal application which comes with macOS.

Homebrew package manager

Install the Homebrew package manager.

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

Apple Silicon users (“M1”, “M2”, etc.) only - Homebrew installs to a non-standard location, /opt/homebrew/. You’ll need to run the following to add Homebrew to your path:

$ echo 'eval "$(/opt/homebrew/bin/brew shellenv)"' >> ~/.zprofile

Close your terminal and reopen your terminal.

Check your install. Your version might be different.

$ brew --version
Homebrew 3.6.14

Install CLI tools

Use the Homebrew package manager to install a few command line programs.

$ brew install wget git tree

Acknowledgments

Original document written by Andrew DeOrio awdeorio@umich.edu.

This document is licensed under a Creative Commons Attribution-NonCommercial 4.0 License. You’re free to copy and share this document, but not to sell it. You may not share source code provided with this document.