diff options
author | Kat Marchán <kzm@zkat.tech> | 2018-08-21 01:41:52 +0300 |
---|---|---|
committer | Kat Marchán <kzm@zkat.tech> | 2018-08-21 02:17:50 +0300 |
commit | d8e811d6adf3d87474982cb831c11316ac725605 (patch) | |
tree | 67fe6665e852e79b69e448e305f5e716a792d418 /bin | |
parent | 577144cc87b8875206680629c0464e80ee49fbc6 (diff) |
update-notifier: skip checking for updates in CI environments
PR-URL: https://github.com/npm/cli/pull/33
Credit: @Sibiraj-S
Reviewed-By: @zkat
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/npm-cli.js | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/bin/npm-cli.js b/bin/npm-cli.js index e4da63c97..6f76b2382 100755 --- a/bin/npm-cli.js +++ b/bin/npm-cli.js @@ -83,9 +83,11 @@ ) { const pkg = require('../package.json') let notifier = require('update-notifier')({pkg}) + const isCI = require('ci-info').isCI if ( notifier.update && - notifier.update.latest !== pkg.version + notifier.update.latest !== pkg.version && + !isCI ) { const color = require('ansicolors') const useColor = npm.config.get('color') |