I've just installed Homebrew. When I run brew doctor
I get this
Warning: Some directories in /usr/local/share/man aren't writable. This can happen if you "sudo make install" software that isn't managed by Homebrew. If a brew tries to add locale information to one of these directories, then the install will fail during the link step. You should probably `chown` them: /usr/local/share/man/de
What does "You should probably `chown' them" mean? Can someone explain what exactly Homebrew wants me to do?
The command chown /ˈtʃoʊn/, an abbreviation of change owner, is used on Unix and Unix-like operating systems to change the owner of file system files, directories. Unprivileged (regular) users who wish to change the group membership of a file that they own may use chgrp.
chown (or “change owner”) dictates who owns a file. If you want to change what users can do with a file, you probably want chmod. If you want to change the owner of a file, you probably want chown.
The chown command allows you to change the user and/or group ownership of a given file, directory, or symbolic link. In Linux, all files are associated with an owner and a group and assigned with permission access rights for the file owner, the group members, and others.
Ok, so chown
is the unix command to change the ownership of a file.
Homebrew is asking me to change the ownership of /usr/local/share/man/de
so that Homebrew can write to it. Homebrew runs with the same permissions as I do, so making myself the file's owner should solve the problem.
Running the following fixes the problem:
sudo chown $(whoami) /usr/local/share/man/de
Check the owner and the permission rights:
ls -la /usr/local/share/man/ | grep de; ls -la /usr/local/share/man/de/ | grep man1
Change it:
/usr/bin/sudo /usr/bin/chgrp admin /usr/local/share/man/de /usr/local/share/man/de/man1 /usr/bin/sudo /bin/chmod g+rwx /usr/local/share/man/de /usr/local/share/man/de/man1
Now you can use brew
without any problems ;-)
Your system is ready to brew.
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