新手在这里。
我花了好几个小时。目标是安装Poylmer,我尝试安装bower到底。然后做了Poylmer zip文件并将其放在myproject目录中。
我正在尝试做10分钟的教程LOL它需要凉亭,我还没有成功。 Node,npm和Git显示了良好的安装。跑更新。重新启动。尝试再次安装。
然后检查节点版本
pi@raspberrypi ~ $ sudo apt-get install node
Reading package lists... Done
Building dependency tree
Reading state information... Done
node is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded
仍然得到这个:
pi@raspberrypi ~ $ sudo apt-get install bower
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package bower
pi@raspberrypi ~ $ sudo npm install -g bower
npm http GET http://registry.npmjs.org/bower
npm http 304 http://registry.npmjs.org/bower
npm ERR! Error: No compatible version found: bower
npm ERR! No valid targets found.
npm ERR! Perhaps not compatible with your version of node?
npm ERR! at installTargetsError (/usr/share/npm/lib/cache.js:488:10)
npm ERR! at next_ (/usr/share/npm/lib/cache.js:438:17)
npm ERR! at next (/usr/share/npm/lib/cache.js:415:44)
npm ERR! at /usr/share/npm/lib/cache.js:408:5
npm ERR! at saved (/usr/share/npm/lib/utils/npm-registry-client/get.js:147:7)
npm ERR! at Object.oncomplete (/usr/lib/nodejs/graceful-fs.js:230:7)
npm ERR! You may report this log at:
npm ERR! <http://bugs.debian.org/npm>
npm ERR! or use
npm ERR! reportbug --attach /home/pi/npm-debug.log npm
npm ERR!
npm ERR! System Linux 3.18.7-v7+
npm ERR! command "/usr/bin/nodejs" "/usr/bin/npm" "install" "-g" "bower"
npm ERR! cwd /home/pi
npm ERR! node -v v0.6.19
npm ERR! npm -v 1.1.4
npm ERR! message No compatible version found: bower
npm ERR! message No valid targets found.
npm ERR! message Perhaps not compatible with your version of node?
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /home/pi/npm-debug.log
npm not ok
pi@raspberrypi ~ $
我的截止日期快到了。非常感谢所有帮助。谢谢!
答案 0 :(得分:-1)
使用Bower
安装npm
对我有用。 apt-get install
中的Bower
不起作用。
尝试以下命令:sudo npm install -g bower