Skip to content

Commit b179a70

Browse files
clydinfilipesilva
authored andcommitted
fix(@angular/cli): ensure odd number Node.js version message is a warning
Fixes: #20050
1 parent 1f83f30 commit b179a70

File tree

1 file changed

+3
-0
lines changed
  • packages/angular/cli/bin

1 file changed

+3
-0
lines changed

packages/angular/cli/bin/ng

+3
Original file line numberDiff line numberDiff line change
@@ -24,12 +24,15 @@ if (version[0] % 2 === 1 && version[0] > 14) {
2424
'Odd numbered Node.js versions will not enter LTS status and should not be used for production.' +
2525
' For more information, please see https://nodejs.org/en/about/releases/.',
2626
);
27+
28+
require('../lib/init');
2729
} else if (
2830
version[0] < 12 ||
2931
version[0] === 13 ||
3032
(version[0] === 12 && version[1] < 13) ||
3133
(version[0] === 14 && version[1] < 15)
3234
) {
35+
// Error and exit if less than 12.13 or 13.x or less than 14.15
3336
console.error(
3437
'Node.js version ' +
3538
process.version +

0 commit comments

Comments
 (0)