Rangeslider.js无法安装

时间:2017-06-30 20:45:39

标签: node.js npm bower npm-install bower-install

我正在尝试安装和使用rangeslider.js API,我已经下载了最新版本,我已经开始使用npm和bower install命令通过终端安装它。当我尝试npm安装时,我收到以下错误:

npm WARN checkPermissions Missing write access to /Users/Brian/node_modules
npm WARN enoent ENOENT: no such file or directory, open '/Users/Brian/package.json'
npm WARN Brian No description
npm WARN Brian No repository field.
npm WARN Brian No README data
npm WARN Brian No license field.

npm ERR! path /Users/Brian/node_modules
npm ERR! code EACCES
npm ERR! errno -13
npm ERR! syscall access
npm ERR! Error: EACCES: permission denied, access '/Users/Brian/node_modules'
npm ERR!  { Error: EACCES: permission denied, access '/Users/Brian/node_modules'
npm ERR!   errno: -13,
npm ERR!   code: 'EACCES',
npm ERR!   syscall: 'access',
npm ERR!   path: '/Users/Brian/node_modules' }
npm ERR! 
npm ERR! Please try running this command again as root/Administrator.

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/Brian/.npm/_logs/2017-06-30T20_40_33_877Z-debug.log

当我尝试凉亭安装时,我得到了这个:

bower cached        https://github.com/andreruffert/rangeslider.js.git#2.3.0
bower validate      2.3.0 against https://github.com/andreruffert/rangeslider.js.git#*
bower no-json       No bower.json file to save to, use bower init to create one

bower安装上的最后一条消息似乎很清楚,我需要创建某种jSON文件,但我不知道它的要求是什么以及我需要将它保存到哪里。有人可以帮忙吗?在你们都提出建议之前:sudo install并没有解决任何问题。

0 个答案:

没有答案