Hacker News new | ask | show | jobs
by crabique 337 days ago
The trick for smooth experience is to treat it like `pacman -Syu`:

  brew update && brew upgrade && brew autoremove && brew cleanup && brew doctor
Running this every few days and fixing everything that it explicitly complains about kept me issue-free for the last 10 years or so.
1 comments

Interesting, thank you. That makes sense, but it is not convenient IMO.
I guess it could just be a cron job
I wouldn't recommend doing it from a cronjob, there are sometimes things that require sudo to update, breaking changes and important notes from Brew maintainers in the output. It's really important to inspect the output in order to see everything Brew doesn't consider normal.

Lately I'm running this like once every 2-3 weeks and it's still surprisingly nice to use. The problems only really manifest when you never run this "maintenance" snippet and only use the `brew install`, which will attempt to do the housekeeping stuff when you want/expect it the least.