Homebrew Cheatsheet
#
Homebrew is a package manager for macOS that simplifies the installation and management of software.
Package Management
#
Command/Option | Example | Description |
---|
brew install | brew install wget | Install a package |
brew uninstall | brew uninstall wget | Uninstall a package |
brew update | brew update | Update Homebrew to the latest version |
brew upgrade | brew upgrade | Upgrade all installed packages to their latest versions |
brew list | brew list | List all installed packages |
brew info | brew info wget | Display information about a package |
Searching and Tapping
#
Command/Option | Example | Description |
---|
brew search | brew search wget | Search for a package |
brew tap | brew tap homebrew/cask | Add a new tap to Homebrew |
brew untap | brew untap homebrew/cask | Remove a tap from Homebrew |
Casks (GUI Applications)
#
Command/Option | Example | Description |
---|
brew install --cask | brew install --cask google-chrome | Install a GUI application using cask |
brew uninstall --cask | brew uninstall --cask google-chrome | Uninstall a GUI application |
brew list --cask | brew list --cask | List all installed casks |
brew info --cask | brew info --cask google-chrome | Display information about a cask |
Configuration and Maintenance
#
Command/Option | Example | Description |
---|
brew doctor | brew doctor | Check your system for potential issues with Homebrew |
brew cleanup | brew cleanup | Remove old versions of installed packages |
brew services start | brew services start mysql | Start a service managed by Homebrew |
brew services stop | brew services stop mysql | Stop a service managed by Homebrew |
brew services list | brew services list | List all services managed by Homebrew and their statuses |
Additional Commands
#
Command/Option | Example | Description |
---|
brew config | brew config | Display Homebrew’s configuration |
brew version | brew version | Show the version of Homebrew |
This cheatsheet covers the essential Homebrew commands and options for managing packages and applications on macOS.