node.js - 无法安装 twitter bootstrap node.js 依赖项(在 Ubuntu 上)

标签 node.js twitter-bootstrap-3 ubuntu-14.04

我已经从 official website 下载了 Bootstrap 3.1.1 源文件当我按照 bootstrap setup directions 尝试在 bootstrap/ 目录中运行 npm install 时,出现错误从网站。

我使用的是 Ubuntu 14.04 平台,从分发存储库安装了 npm 1.3.10,并且可以成功运行 npm install -g grunt-cli,没有任何问题。

但是,当我尝试从引导目录中 sudo npm install 时,我看到一长串成功的 GET 消息,然后该消息终止并出现以下错误:

npm http 304 https://registry.npmjs.org/proto-list

> phantomjs@1.9.7-4 install /home/cboettig/Documents/code/thirdparty/bootstrap/node_modules/grunt-contrib-qunit/node_modules/grunt-lib-phantomjs/node_modules/phantomjs
> node install.js

npm WARN This failure might be due to the use of legacy binary "node"
npm WARN For further explanations, please read
/usr/share/doc/nodejs/README.Debian

npm ERR! weird error 1
npm ERR! not ok code 0

我查阅了警告中提到的README.Debian,它似乎只是说Debian平台需要调用nodejs而不是node 以避免命名空间冲突。我不确定如何验证这是否有问题。

我发现错误消息奇怪的错误1也不是特别有帮助。

如何干净地安装这个项目而不出现错误?

最佳答案

运行这些命令

sudo add-apt-repository ppa:chris-lea/node.js
sudo apt-get update
sudo apt-get install python-software-properties python g++ make nodejs

从存储库安装node.js。

关于node.js - 无法安装 twitter bootstrap node.js 依赖项(在 Ubuntu 上),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/23251351/

相关文章:

c# - 按钮与文本框水平内联 Razor View

java - bash:/usr/local/android-sdk-linux/tools/android: 权限被拒绝

hadoop - -su : ./start-all.sh: Ubuntu 中没有这样的文件或目录

javascript - request.settimeout nodejs 似乎不起作用?

node.js - 使用 Sequelize 编写查询

node.js - 无法在 Node js中显示静态文件夹中的图像

jquery - Bootstrap Nested Navbars - 控制 "active"类

node.js - Strongloop Oracle 通过脚本连接

twitter-bootstrap - Bootstrap 的菜单设计问题

c++ - 编译并运行文件夹中提供的 MySQL++ 和 C++ 示例