MacOS – Does homebrew usually put lots of files in the /usr/local folder itself

homebrewmacos

Doing ls -ltra /usr/local gives a lot of homebrew files and folders in /usr/local itself, as opposed to a subfolder:

$ ls -ltra /usr/local/
total 56
drwxr-xr-x@  12 root    wheel    408 13 Jul  2015 ..
drwxr-xr-x    7 65535   65535    238 24 Jul  2015 heroku
drwxr-xr-x    6 agrimm  admin    204 24 Jul  2015 foreman
-rw-r--r--    1 agrimm  admin    291  7 Oct  2015 .yardopts
-rw-r--r--    1 agrimm  admin   1241 15 Jan 16:19 LICENSE.txt
drwx------    8 agrimm  admin    272 15 Jan 16:25 var
drwxr-xr-x    8 agrimm  admin    272 15 Jan 16:31 etc
-rw-r--r--@   1 agrimm  admin   3161  4 Apr 14:48 CODEOFCONDUCT.md
-rw-r--r--    1 agrimm  admin    861 12 May 09:16 .travis.yml
drwxr-xr-x   34 agrimm  admin   1156 12 May 09:17 share
drwxr-xr-x  303 agrimm  admin  10302 23 Jun 09:21 lib
drwxr-xr-x   98 agrimm  admin   3332 23 Jun 09:22 include
-rw-r--r--@   1 agrimm  admin   4266 23 Jun 09:51 README.md
-rw-r--r--    1 agrimm  admin   1031 23 Jun 09:51 .gitignore
drwxr-xr-x    5 agrimm  admin    170 23 Jun 09:51 .github
drwxrwxr-x   21 root    admin    714 23 Jun 09:51 .
drwxr-xr-x   12 agrimm  admin    408 23 Jun 09:56 Library
drwxr-xr-x  256 agrimm  admin   8704  6 Jul 11:50 bin
drwxr-xr-x   60 agrimm  admin   2040  6 Jul 11:50 opt
drwxr-xr-x   60 agrimm  admin   2040  6 Jul 11:50 Cellar
drwxr-xr-x   15 agrimm  admin    510 13 Jul 10:50 .git

CODEOFCONDUCT.md, LICENSE.txt, README.md, .git, .gitignore, Library, bin, opt, Cellar and probably other files and folders refer to homebrew.

Is this normal for homebrew when I chose "Install" for Xcode, and then installed homebrew as per the following?

$ ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
==> This script will install:
/usr/local/bin/brew
/usr/local/Library/...
/usr/local/share/man/man1/brew.1

Press RETURN to continue or any other key to abort
==> /usr/bin/sudo /bin/mkdir /usr/local

WARNING: Improper use of the sudo command could lead to data loss
or the deletion of important system files. Please double-check your
typing when using sudo. Type "man sudo" for more information.

To proceed, enter your password, or type Ctrl-C to abort.

Password:
==> /usr/bin/sudo /bin/chmod g+rwx /usr/local
==> /usr/bin/sudo /usr/bin/chgrp admin /usr/local
==> /usr/bin/sudo /bin/mkdir /Library/Caches/Homebrew
==> /usr/bin/sudo /bin/chmod g+rwx /Library/Caches/Homebrew
==> Installing the Command Line Tools (expect a GUI popup):
==> /usr/bin/sudo /usr/bin/xcode-select --install
xcode-select: note: install requested for command line developer tools
Press any key when the installation has completed.
==> Downloading and installing Homebrew...
remote: Counting objects: 3660, done.
remote: Compressing objects: 100% (3491/3491), done.
remote: Total 3660 (delta 35), reused 673 (delta 28), pack-reused 0
Receiving objects: 100% (3660/3660), 2.97 MiB | 371.00 KiB/s, done.
Resolving deltas: 100% (35/35), done.
From https://github.com/Homebrew/homebrew
 * [new branch]      master     -> origin/master
HEAD is now at 3947f85 consul: add 0.5.2 bottle.
==> Installation successful!
==> Next steps
Run `brew help` to get started

For what it's worth, I've also installed cask.

Best Answer

Yes. That's how homebrew does.

You can usually trust

brew doctor

to tell if things are correct - it is pretty good about flagging anything amiss in /usr/local.

But to confirm your main question, the normal for homebrew it that it's noted for being "chatty" in that directory with many files and folders.