I've been trying to use homebrew to install python and finally gotten that to work. In the process of trying to make that work I ran:
brew list --unbrewed
and got a huge list of files (over 59,000). These files are mostly related to python, node, ruby, mongo and mysql. I've also run brew update and brew doctor and neither one of those have any effect on the unbrewed list.
It seems like not such a great idea to keep my installation in this state. So I guess I have several questions about this:
1) Is this something that I should worry about or fix?
2) Where are the unbrewed files kept? (I looked for documentation on this but couldn't find it). Many of these files don't exist at the path shown so where are they?
3) If I did want to clean this up how would I do so? And will I end up removing my installations of these packages/formulas?
This is nothing to worry about. Homebrew is designed to play well with other things that install in to /usr/local/
, which is the standard place for user-built software to go. Plenty of other things install themselves there. The brew list --unbrewed
comamnd just lists all the files under /usr/local
which weren't put there by Homebrew. It is not diagnostic of an actual problem, it's more for identifying stuff you might want to put under a Homebrew formula, or to help formula maintainers check for stray files while doing installation work. Any normal system will probably have a nonempty brew list --unbrewed
.
Do a brew doctor
instead. That checks for files in certain places under /usr/local
which could actually be problematic. If brew doctor
complains about something, you probably need to address that. Otherwise, don't worry about them, and don't try to clean them up - you probably put those files there for a reason.
Here's an example of what my test 10.8.3 system reports. Plenty of --unbrewed
files, but doctor
is happy. Homebrew is functioning just fine on it.
$ brew list --unbrewed | wc
1721 1727 82663
$ brew doctor
Your system is ready to brew.
So:
1) No, don't worry about this or fix it unless brew doctor
tells you to. Removing these files will probably break something you installed.
2) Those paths are relative to brew --prefix
, which is probably /usr/local
.
3) Hypothetically, to "clean it up", for each file, you'd just determine what installed it and uninstall it, reinstalling it using a Homebrew formula if it's something you actually need, or come to a conclusion that it was a mistake or no longer needed, and delete it. There's no standard or easy way to do this. And that is exactly the problem that Homebrew and other package managers exist to solve.
Some of that might be worthwhile if you want to use Homebrew more extensively to control your installations. Each time you're about to install some non-Homebrew software that sticks itself in /usr/local/
, instead of following the normal installation instructions, use brew create
to make a formula for it. Then homebrew will track the files it installs.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With