Homebrew|Homebrew mac Error: Permission denied @ apply2files - /usr/local/lib/cmake/libwebsockets

【Homebrew|Homebrew mac Error: Permission denied @ apply2files - /usr/local/lib/cmake/libwebsockets】今天用MacBook编译以前的一个C语言项目时发现以前安装过的cmake没有了,于是用homebrew重新安装一下: brew install cmake
虽然「cmake」安装成功了但是下面跟着一个错误:

Error: Permission denied @ apply2files - /usr/local/lib/cmake/libwebsockets
意思是说没有权限访问这个目录,给当前用户授权(改变拥有者)就可以了:
sudo chown -R $(whoami) /usr/local

    推荐阅读