使用 sudo 命令后或者当前用户为 root,执行 bower 相关命令会出现错误:spa
解决办法:3d
在命令后面加 --allow-rootblog
例:bower
bower init --allow-rootit
bower install --allow-root 文件名im