This morning, I recovered 110 GB of disk space thanks to one command.
I'm a heavy homebrew user. I install packages all the time. On top of that, I brew update and brew upgrade quite often. I like to stay up to date.
Over the years, I continued to install packages, update, and upgrade them. All the while I was ignoring one important command.
My Story
This morning, I was greeted with this alert. Hmmmm... I thought. What could this be?
My documents folder had a few gigabytes of data, but that wasn't filling up my entire disk. That's when I started exploring homebrew packages. I realized I had been keeping many, many old homebrew packages around for no reason.
The Command
That's when I ran the command brew cleanup
. Oh boy, I was in for a surprise. My terminal started spitting out line after line of this:
That's a lot of disk space!
After that completed (which took about 15 minutes), I suddenly had 120 GB of free space to work with. And that got me thinking, what else do I not know about homebrew? Do you have any tips for us homebrew users out there?
Top comments (3)
There's an argument switch to have homebrew do clean-up every time it upgrades!
Ah ah the magic cleanup!
I created an alias so I won't forget:
==> This operation has freed approximately 417.6MB of disk space.
My tip would be to use a Brewfile: robots.thoughtbot.com/brewfile-a-g...