解决办法

sudo chown -R USER /usr/local/bin

sudo chown -RUSER /usr/local/lib/node_modules