2016-07-04 86 views
4
$ npm update [email protected] 

$ npm update -d 
npm info it worked if it ends with ok 
npm info using [email protected] 
npm info using [email protected] 
npm info attempt registry request try #1 at 5:33:55 PM 
npm http request GET https://registry.npmjs.org/jshint 
npm http 200 https://registry.npmjs.org/jshint 
npm info ok 


$ npm install jshint 
npm WARN deprecated [email protected]: Please update to minimatch 3.0.2 or higher                             to avoid a RegExp DoS issue 
npm WARN deprecated [email protected]: Please update to minimatch 3.0.2 or higher                             to avoid a RegExp DoS issue 
[email protected] node_modules\jshint 
├── [email protected] 
├── [email protected] 
├── [email protected] 
├── [email protected] ([email protected]) 
├── [email protected] 
├── [email protected] ([email protected]) 
├── [email protected] ([email protected], [email protected], [email protected], d                            [email protected], [email protected]) 
└── [email protected] ([email protected]) 
+0

npm WARN弃用[email protected]:请更新至minimatch 3.0.2或更高版本以避免RegExp DoS问题 –

+1

这很好。你有问题吗?这个网站是编程问题,而不是转储一些终端输出的地方。 –

+0

是的我的问题是你之前遇到过这个问题还是有一个想法如何解决它 –

回答

0

试试这个(为OSX)

进入终端须藤乔敦 - R的$ USER的/ usr /本地

+0

虽然这是一种解决这个问题的方法,但我始终认为这是最不利的。而不是更改系统文件的所有者,运行'npm config set prefix $ HOME/.node_modules'更有意义https://docs.npmjs.com/getting-started/fixing-npm-permissions –

0

适用于我降级到节点v4.4.7并在终端中使用sudo chown -R $ USER/usr/local。

1

很抱歉这么晚才回复..

sudo npm install 

尝试this..this作品对我来说,安装NPM

要更新使用这个..

sudo npm install -g [email protected] 
相关问题