Skip to content

Commit

Permalink
Reduce nodejs version >= 17 error to a warning in order to allow for …
Browse files Browse the repository at this point in the history
…smooth bisects in the future (#150969)
  • Loading branch information
alexdima committed Jun 1, 2022
1 parent 37fb265 commit 345c867
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion build/npm/preinstall.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,13 @@ const majorNodeVersion = parseInt(nodeVersion[1]);
const minorNodeVersion = parseInt(nodeVersion[2]);
const patchNodeVersion = parseInt(nodeVersion[3]);

if (majorNodeVersion < 16 || (majorNodeVersion === 16 && minorNodeVersion < 14) || majorNodeVersion >= 17) {
if (majorNodeVersion < 16 || (majorNodeVersion === 16 && minorNodeVersion < 14)) {
console.error('\033[1;31m*** Please use node.js versions >=16.14.x and <17.\033[0;0m');
err = true;
}
if (majorNodeVersion >= 17) {
console.warn('\033[1;31m*** Warning: Versions of node.js >= 17 have not been tested.\033[0;0m')
}

const path = require('path');
const fs = require('fs');
Expand Down

0 comments on commit 345c867

Please sign in to comment.