How do I reinstall all packages installed with Homebrew?

It's as simple as that:

$ brew list | xargs brew reinstall

You don't need to uninstall anything, because doing so you may lose your settings and configs.


to keep not only installed brews but also casks and taps i recommend to

$ brew bundle dump --describe --global
$ brew bundle install --global

the first command will write ~/.Brewfile which will be read again in the second call. it looks like this:

$ cat ~/.Brewfile
tap "buo/cask-upgrade"
tap "homebrew/cask-fonts"
brew "direnv"
brew "python"
cask "0xed"
cask "alacritty"

please issue

$ brew bundle -h

for more details on the bundle command.

Tags:

Macos

Homebrew