Wednesday 24 May 2017

NPM not working after setting proxy

I was trying to set proxy using this command

npm config set proxy "http://domain%5Cusername:password@servername:port/

After setting the proxy, when i use npm or any npm command i get the below error. I think i've messed up the config file. I just want to restore my npm to old state.

Please help!!

URIError: URI malformed
at decodeURIComponent( < anonymous > )
at Url.parse(url.js: 269: 19)
at Object.urlParse[as parse](url.js: 75: 5)
at Object.validateUrl[as validate](C: \node\ node_modules\ npm\ node_modules\ n opt\ lib\ nopt.js: 172: 13)
at validate(C: \node\ node_modules\ npm\ node_modules\ nopt\ lib\ nopt.js: 221: 24)
at validate(C: \node\ node_modules\ npm\ node_modules\ nopt\ lib\ nopt.js: 187: 11)
at C: \node\ node_modules\ npm\ node_modules\ nopt\ lib\ nopt.js: 104: 12
at Array.map(native)
at C: \node\ node_modules\ npm\ node_modules\ nopt\ lib\ nopt.js: 70: 15
at Array.forEach(native)

C: \node\ node_modules\ npm\ lib\ npm.js: 45
throw new Error('npm.load() required') ^


via Arun

No comments:

Post a Comment