执行其他命令,例如 npm install 没问题,只有npm search报错是什么原因呢 ?请教一下大神。
npm-debug.log 内容如下
0 info it worked if it ends with ok 1 verbose cli [ '/usr/local/bin/node',
1 verbose cli '/usr/local/bin/npm',
1 verbose cli 'search',
1 verbose cli 'birdblue' ]
2 info using [email protected]
3 info using [email protected]
4 silly mapToRegistry name -/all
5 silly mapToRegistry using default registry
6 silly mapToRegistry registry https://registry.npm.taobao.org/
7 silly mapToRegistry data Result {
7 silly mapToRegistry raw: '-/all',
7 silly mapToRegistry scope: null,
7 silly mapToRegistry name: null,
7 silly mapToRegistry rawSpec: '-/all',
7 silly mapToRegistry spec: '-/all',
7 silly mapToRegistry type: 'local' }
8 silly mapToRegistry uri https://registry.npm.taobao.org/-/all
9 info updateIndex /Users/erobaby/.npm/registry.npm.taobao.org/-/all/.cache.json
10 verbose correctMkdir /Users/erobaby/.npm correctMkdir not in flight; initializing
11 warn Building the local index for the first time, please be patient
12 silly update-index fetching https://registry.npm.taobao.org/-/all
13 verbose request uri https://registry.npm.taobao.org/-/all
14 verbose request no auth needed
15 info attempt registry request try #1 at 10:09:21 PM
16 verbose request id 42795a828884fa6f
17 http request GET https://registry.npm.taobao.org/-/all
18 http 200 https://registry.npm.taobao.org/-/all
19 verbose headers { date: 'Tue, 24 May 2016 14:09:25 GMT',
19 verbose headers 'content-type': 'application/json; charset=utf-8',
19 verbose headers 'content-length': '6353839',
19 verbose headers connection: 'keep-alive',
19 verbose headers etag: '"60f3af-JoOug2jyagvkE0Rh498e7g"',
19 verbose headers 'x-readtime': '4026' }
20 verbose stack Error: true true: -/all
20 verbose stack at makeError (/usr/local/lib/node_modules/npm/node_modules/npm-registry-client/lib/request.js:264:12)
20 verbose stack at CachingRegistryClient.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/npm-registry-client/lib/request.js:252:14)
20 verbose stack at Request._callback (/usr/local/lib/node_modules/npm/node_modules/npm-registry-client/lib/request.js:172:14)
20 verbose stack at Request.self.callback (/usr/local/lib/node_modules/npm/node_modules/request/request.js:200:22)
20 verbose stack at emitTwo (events.js:106:13)
20 verbose stack at Request.emit (events.js:191:7)
20 verbose stack at Request.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/request/request.js:1067:10)
20 verbose stack at emitOne (events.js:101:20)
20 verbose stack at Request.emit (events.js:188:7)
20 verbose stack at IncomingMessage.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/request/request.js:988:12)
21 verbose statusCode 200
22 verbose cwd /Users/erobaby/Workspace/node-study
23 error Darwin 15.0.0
24 error argv "/usr/local/bin/node" "/usr/local/bin/npm" "search" "birdblue"
25 error node v6.2.0
26 error npm v3.8.9
27 error code E200
28 error true true: -/all
29 error If you need help, you may report this error at:
29 error <https://github.com/npm/npm/issues>
30 verbose exit [ 1, true ]