Skip to content

Commit

Permalink
npm outdated: fix silent exit code
Browse files Browse the repository at this point in the history
  • Loading branch information
dkrnl committed Oct 23, 2021
1 parent cd0efef commit 51e5516
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 19 deletions.
36 changes: 18 additions & 18 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion script.update.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ const weblog = require('webpack-log');
const logger = weblog({ name: 'update' });

logger.info('npm outdate');
const outdated = Object.entries(JSON.parse(childProcess.execSync('npm outdate --json').toString() || '{}'));
const outdated = Object.entries(JSON.parse(childProcess.execSync('npm outdate --json || true').toString() || '{}'));

const missing = outdated.filter(([, version]) => !version.location || version.current !== version.wanted);
logger.info(`missing ${missing.length} packages`);
Expand Down

0 comments on commit 51e5516

Please sign in to comment.