From 212266529ae72056bf0876e2cff4b8ba01d09d0f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kat=20March=C3=A1n?= Date: Wed, 16 May 2018 01:19:38 -0700 Subject: update-notifier: remove colon + support canary (#20536) PR-URL: https://github.com/npm/npm/pull/20536 Credit: @zkat Reviewed-By: @iarna --- bin/npm-cli.js | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'bin/npm-cli.js') diff --git a/bin/npm-cli.js b/bin/npm-cli.js index f8fd106d2..d7c14bc4b 100755 --- a/bin/npm-cli.js +++ b/bin/npm-cli.js @@ -102,7 +102,7 @@ } const changelog = `https://github.com/npm/npm/releases/tag/v${latest}` notifier.notify({ - message: `New ${type} version of npm available! ${ + message: `New ${type} version of ${pkg.name} available! ${ useColor ? color.red(old) : old } ${useUnicode ? '→' : '->'} ${ useColor ? color.green(latest) : latest @@ -110,10 +110,12 @@ `${ useColor ? color.yellow('Changelog:') : 'Changelog:' } ${ - useColor ? color.cyan(changelog + ':') : changelog + ':' + useColor ? color.cyan(changelog) : changelog }\n` + `Run ${ - useColor ? color.green('npm install -g npm') : 'npm i -g npm' + useColor + ? color.green(`npm install -g ${pkg.name}`) + : `npm i -g ${pkg.name}` } to update!` }) } -- cgit v1.2.3