Reputation: 292
No npm command (all!) is working on my Windows 10.
Example:
npm -v
It does not display any information and cmd crashes. Only unlocks if I hit CTR + C and inform "Y":
I've tried reinstalling node.js (v6.6.0 x64 and v5.12.0 x86), tried npm versions v3.10.3 and v3.10.7, but all without success.
How can I fix it?
NEWS:
My conf.get('prefix')
in afterUser() function on nodejs\node_modules\npm\lib\config\core.js
it is returning the wrong directory: C:\Users\Alisson Linneker\'C:\Program
I believe that this is the problem!
Problem solved!
In nodejs\node_modules\npm\lib\config\core.js
afterUser() function, add before if (conf.get('prefix')) {
line:
conf.set('prefix', path.resolve(__dirname, '../..', ''))
Upvotes: 0
Views: 1066
Reputation: 292
In nodejs\node_modules\npm\lib\config\core.js
afterUser() function, add before if (conf.get('prefix')) {
line:
conf.set('prefix', path.resolve(__dirname, '../..', ''))
Pull request: https://github.com/npm/npm/pull/13995
Upvotes: 0
Reputation: 6377
For Windows I use Virtual Box with Ubuntu. If you set that up you will have an easier time.
Upvotes: 1