After installing and uninstalling some programs through brew
and brew cask
, now I get brew doctor
saying \"unlinked kegs in your Cellar\".
brew cleanup [options] [formula|cask]
Remove stale lock files and outdated downloads for all formulae and casks, and remove old versions of installed formulae. If arguments are specified, only do this for the given formulae and casks.
--prune Remove all cache files older than specified days. -n, --dry-run Show what would be removed, but do not actually remove anything. -s Scrub the cache, including downloads for even the latest versions. Note downloads for any installed formula or cask will still not be deleted. If you want to delete those too: rm -rf "$(brew --cache)" --prune-prefix Only prune the symlinks and directories from the prefix and remove no other files. -v, --verbose Make some output more verbose. -d, --debug Display any debugging information. -h, --help Show this message.
brew prune [--dry-run]: Remove dead symlinks from the Homebrew prefix. This is generally not needed, but can be useful when doing DIY installations. Also remove broken app symlinks from /Applications and ~/Applications that were previously created by brew linkapps.
If --dry-run or -n is passed, show what would be removed, but do not actually remove anything.