Skip to content
This repository has been archived by the owner. It is now read-only.
Permalink
Browse files

error-message: Shorten the ELIFECYCLE error message

Credit: @j-f1
Reviewed-By: @iarna
PR-URL: #16364
Fixes: #8821
  • Loading branch information...
j-f1 authored and iarna committed Apr 17, 2017
1 parent 0a6772b commit 65b9943e9424c67547b0029f02b0258e35ba7d26
Showing with 3 additions and 12 deletions.
  1. +2 −11 lib/utils/error-message.js
  2. +1 −1 test/tap/spawn-enoent.js
@@ -33,17 +33,8 @@ function errorMessage (er) {
'',
[
'',
'Failed at the ' + er.pkgid + ' ' + er.stage + " script '" + er.script + "'.",
'Make sure you have the latest version of node.js and npm installed.',
'If you do, this is most likely a problem with the ' + er.pkgname + ' package,',
'not with npm itself.',
'Tell the author that this fails on your system:',
' ' + er.script,
'You can get information on how to open an issue for this project with:',
' npm bugs ' + er.pkgname,
'Or if that isn\'t available, you can get their info via:',
' npm owner ls ' + er.pkgname,
'There is likely additional logging output above.'
'Failed at the ' + er.pkgid + ' ' + er.stage + ' script.',
'This is probably not a problem with npm. There is likely additional logging output above.'
].join('\n')]
)
break
@@ -28,7 +28,7 @@ test('enoent script', function (t) {
'npm_config_loglevel': 'warn'
}
}, function (er, code, sout, serr) {
t.similar(serr, /npm ERR! Failed at the x@1\.2\.3 start script 'wharble-garble-blorst'\./)
t.similar(serr, /npm ERR! Failed at the x@1\.2\.3 start script\./)
t.end()
})
})

0 comments on commit 65b9943

Please sign in to comment.
You can’t perform that action at this time.