Command line 鲍尔安装问题
使用Bower添加包时,每次我不知道如何解决问题时都会收到此错误消息 我试图通过执行以下操作加载font awesome或bower安装Command line 鲍尔安装问题,command-line,bower,bower-install,Command Line,Bower,Bower Install,使用Bower添加包时,每次我不知道如何解决问题时都会收到此错误消息 我试图通过执行以下操作加载font awesome或bower安装 $ bower install --save font-awesome $ bower install 但我得到了一个错误: usr/local/lib/node_modules/bower/lib/node_modules/configstore/index.js:54 throw err;
$ bower install --save font-awesome
$ bower install
但我得到了一个错误:
usr/local/lib/node_modules/bower/lib/node_modules/configstore/index.js:54
throw err;
^
Error: EACCES: permission denied, open '/Users/brandonpowell/.config/configstore/bower-github.json'
You don't have access to this file.
at Error (native)
at Object.fs.openSync (fs.js:640:18)
at Object.fs.readFileSync (fs.js:508:33)
at Object.get (/usr/local/lib/node_modules/bower/lib/node_modules/configstore/index.js:35:26)
at Object.Configstore (/usr/local/lib/node_modules/bower/lib/node_modules/configstore/index.js:28:44)
at readCachedConfig (/usr/local/lib/node_modules/bower/lib/config.js:19:23)
at defaultConfig (/usr/local/lib/node_modules/bower/lib/config.js:11:12)
at Object.<anonymous> (/usr/local/lib/node_modules/bower/lib/index.js:16:32)
at Module._compile (module.js:556:32)
at Object.Module._extensions..js (module.js:565:10)
usr/local/lib/node_modules/bower/lib/node_modules/configstore/index.js:54
犯错误;
^
错误:EACCES:权限被拒绝,打开“/Users/brandonpowell/.config/configstore/bower github.json”
您没有访问此文件的权限。
错误(本机)
在Object.fs.openSync(fs.js:640:18)
在Object.fs.readFileSync(fs.js:508:33)
在Object.get(/usr/local/lib/node_modules/bower/lib/node_modules/configstore/index.js:35:26)
在Object.Configstore(/usr/local/lib/node_modules/bower/lib/node_modules/Configstore/index.js:28:44)
在readCachedConfig(/usr/local/lib/node\u modules/bower/lib/config.js:19:23)
在defaultConfig(/usr/local/lib/node_modules/bower/lib/config.js:11:12)
反对。(/usr/local/lib/node_modules/bower/lib/index.js:16:32)
在模块处编译(Module.js:556:32)
在Object.Module._extensions..js(Module.js:565:10)
检查该文件的权限:
ls -laF ~/.config/configstore/bower-github.json
您以前可能以root
用户身份运行过bower
。它应该足以运行:
sudo chown brandonpowell ~/.config/configstore/bower-github.json
它说的是一个非法团体的名字是的,对不起。我只是在猜主要的组名。但是没有必要改变团队。我已经更新了答案。