简体   繁体   English

Bower install命令不会安装任何内容

[英]Bower install command does not install anything

I have troubles getting bower to work on Mac OS X (10.9.3). 我很难在Mac OS X(10.9.3)上使用Bower。

First I made sure no older or conflicting version of bower was installed. 首先,我确保没有安装较旧或冲突的Bower版本。 (Code is the dir) (代码是目录)

➜  Code  which bower
bower not found
➜  Code  bower
zsh: command not found: bower

Then I installed from scratch 然后我从头开始安装

➜  Code  npm install -g bower
/usr/local/bin/bower -> /usr/local/lib/node_modules/bower/bin/bower
bower@1.3.5 /usr/local/lib/node_modules/bower
├── is-root@0.1.0

… etc … 等等

After that, I end up with a half working bower it seems: 在那之后,我似乎半凉了一下:

➜  test  bower lookup jQuery
jQuery git://github.com/jquery/jquery.git
➜  test  bower install jQuery
➜  test  ls -la
total 0
drwxr-xr-x   2 edwin  staff    68 Jun 18 09:59 .
drwxr-xr-x  96 edwin  staff  3264 Jun 18 09:59 ..


➜  test  bower init
➜  test  

What could be the issue here? 这里可能是什么问题?

Some more version info: 一些更多的版本信息:

➜  test  npm -v
1.4.14
➜  test  node -v
v0.10.29
➜  test  bower -v
1.3.5
➜  test  

I solved it. 我解决了 With the new version of bower (1.3.7) I actually got an error message which was informative enough to be able to solve it. 使用新版本的bower(1.3.7),我实际上收到了一条错误消息,该消息具有足够的信息量,能够解决该问题。

bower EACCES        EACCES, permission denied '/Users/edwin/.local/share/bower/empty'

A recursive chown to make the directories my own instead of root made it work again. 将目录设为我自己而不是root的递归chown使它再次起作用。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM