Keeping your Mac clean can be a difficult task if you use Homebrew to install packages for development and testing purpose and without correctly installing the right packages, it may bloat your system, taking up unwanted storage space.

This one command will uninstall all the packages install through Homebrew.

brew remove --force $(brew list) --ignore-dependencies  Code language: JavaScript (javascript)

You can also run.

brew list -1 | xargs brew rmCode language: PHP (php)

To remove unused archives run.

brew cleanup 

To remove Cask packages

brew cask remove --force $(brew cask list)Code language: JavaScript (javascript)

If you have any question, leave a comment.

I compiled a list of software and services that I use to improve my workflow, here is the link to the list.

Darryl Dias

I’m Darryl. I’m a 3D Artist, Programmer and Linux enthusiast. On this site I share my insights, tips and tricks, tutorials, methods and best practices.