无法 "npm install aws-lib"
Unable to "npm install aws-lib"
我是 AWS 的新手,我开始研究 AWS 文档并考虑从 NodeJS 应用程序连接 AWS sdk,为此我安装了 npm aws-lib,如下所示。
你能帮我解决这个问题吗?
appss-MacBook-Pro-2:NodeJS apps$ npm install aws-lib
aws-lib@0.3.0 node_modules/aws-lib
├── underscore@1.5.2
├── xml2js@0.1.14
└── sax@0.1.5
appss-MacBook-Pro-2:NodeJS apps$ npm test
npm ERR! Darwin 15.0.0
npm ERR! argv "node" "/usr/local/bin/npm" "test"
npm ERR! node v0.12.7
npm ERR! npm v2.11.3
npm ERR! path /Users/apps/Desktop/IOT/NodeJS/package.json
npm ERR! code ENOENT
npm ERR! errno -2
npm ERR! enoent ENOENT, open '/Users/apps/Desktop/IOT/NodeJS/package.json'
npm ERR! enoent This is most likely not a problem with npm itself
npm ERR! enoent and is related to npm not being able to find a file.
npm ERR! enoent
npm ERR! Please include the following file with any support request:
npm ERR! /Users/apps/Desktop/IOT/NodeJS/npm-debug.log
appss-MacBook-Pro-2:NodeJS apps$
npm-debug.log
的输出如下:
0 info it worked if it ends with ok
1 verbose cli [ 'node', '/usr/local/bin/npm', 'test' ]
2 info using npm@2.11.3
3 info using node@v0.12.7
4 verbose stack Error: ENOENT, open '/Users/apps/Desktop/IOT/NodeJS/package.json'
4 verbose stack at Error (native)
5 verbose cwd /Users/apps/Desktop/IOT/NodeJS
6 error Darwin 15.0.0
7 error argv "node" "/usr/local/bin/npm" "test"
8 error node v0.12.7
9 error npm v2.11.3
10 error path /Users/apps/Desktop/IOT/NodeJS/package.json
11 error code ENOENT
12 error errno -2
13 error enoent ENOENT, open '/Users/apps/Desktop/IOT/NodeJS/package.json'
13 error enoent This is most likely not a problem with npm itself
13 error enoent and is related to npm not being able to find a file.
14 verbose exit [ -2, true ]
你确实安装了 aws-lib
很好。您可以通过查看项目目录中的 node_modules
目录来验证它。
您接下来要做的是调用 npm test
,但您的 package.json
文件中似乎没有 test
部分,因此 npm
没有test
.
不知道要 运行 做什么
我是 AWS 的新手,我开始研究 AWS 文档并考虑从 NodeJS 应用程序连接 AWS sdk,为此我安装了 npm aws-lib,如下所示。
你能帮我解决这个问题吗?
appss-MacBook-Pro-2:NodeJS apps$ npm install aws-lib aws-lib@0.3.0 node_modules/aws-lib ├── underscore@1.5.2 ├── xml2js@0.1.14 └── sax@0.1.5 appss-MacBook-Pro-2:NodeJS apps$ npm test npm ERR! Darwin 15.0.0 npm ERR! argv "node" "/usr/local/bin/npm" "test" npm ERR! node v0.12.7 npm ERR! npm v2.11.3 npm ERR! path /Users/apps/Desktop/IOT/NodeJS/package.json npm ERR! code ENOENT npm ERR! errno -2 npm ERR! enoent ENOENT, open '/Users/apps/Desktop/IOT/NodeJS/package.json' npm ERR! enoent This is most likely not a problem with npm itself npm ERR! enoent and is related to npm not being able to find a file. npm ERR! enoent npm ERR! Please include the following file with any support request: npm ERR! /Users/apps/Desktop/IOT/NodeJS/npm-debug.log appss-MacBook-Pro-2:NodeJS apps$
npm-debug.log
的输出如下:
0 info it worked if it ends with ok 1 verbose cli [ 'node', '/usr/local/bin/npm', 'test' ] 2 info using npm@2.11.3 3 info using node@v0.12.7 4 verbose stack Error: ENOENT, open '/Users/apps/Desktop/IOT/NodeJS/package.json' 4 verbose stack at Error (native) 5 verbose cwd /Users/apps/Desktop/IOT/NodeJS 6 error Darwin 15.0.0 7 error argv "node" "/usr/local/bin/npm" "test" 8 error node v0.12.7 9 error npm v2.11.3 10 error path /Users/apps/Desktop/IOT/NodeJS/package.json 11 error code ENOENT 12 error errno -2 13 error enoent ENOENT, open '/Users/apps/Desktop/IOT/NodeJS/package.json' 13 error enoent This is most likely not a problem with npm itself 13 error enoent and is related to npm not being able to find a file. 14 verbose exit [ -2, true ]
你确实安装了 aws-lib
很好。您可以通过查看项目目录中的 node_modules
目录来验证它。
您接下来要做的是调用 npm test
,但您的 package.json
文件中似乎没有 test
部分,因此 npm
没有test
.