Homebrew permission issue... again

For some reason I can’t do stuff to /usr/local/lib/node_modules/cordova/node_modules/micromatch/lib/.DS_Store when I do a ‘brew cleanup’.

The bigger issue is that it keeps ‘brew upgrade’ from upgrading all the formulae. I have to upgrade them all individually.

Output of running ‘brew cleanup -d’ and ‘brew doctor’ at pastebin.

https://pastebin.com/wU2xmxqL

You installed cordova globally as root (not needed, just a security risk). And it installed some in places where brew is trying to clean up but can’t because brew never runs as root.

sudo chown -R $(whoami) /usr/local/*

Domo… that worked! So, having it run as root is a security issue?

Running anything as root is a potential security risk because it’ll give the program unlimited access to your pc.