Brew cleanup Error: Permission denied @ unlink_internal

First fix permissions causing the error:

sudo chown -R "$(whoami)":admin /usr/local

On macOS Mojave, the chown command needs to be run on the specific directory, an example for the permissions issue in /usr/local/lib directory, this command would be

sudo chown -R "$(whoami)":admin /usr/local/lib

Then relink node with the --force option as directed:

brew link --overwrite node

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)