From b179a704829fef72191045a443b4b7eb7d20141c Mon Sep 17 00:00:00 2001 From: Charles Lyding <19598772+clydin@users.noreply.github.com> Date: Fri, 12 Feb 2021 21:35:15 -0500 Subject: [PATCH] fix(@angular/cli): ensure odd number Node.js version message is a warning Fixes: #20050 --- packages/angular/cli/bin/ng | 3 +++ 1 file changed, 3 insertions(+) diff --git a/packages/angular/cli/bin/ng b/packages/angular/cli/bin/ng index 2a393779cbdf..09aea2a41bf0 100755 --- a/packages/angular/cli/bin/ng +++ b/packages/angular/cli/bin/ng @@ -24,12 +24,15 @@ if (version[0] % 2 === 1 && version[0] > 14) { 'Odd numbered Node.js versions will not enter LTS status and should not be used for production.' + ' For more information, please see https://nodejs.org/en/about/releases/.', ); + + require('../lib/init'); } else if ( version[0] < 12 || version[0] === 13 || (version[0] === 12 && version[1] < 13) || (version[0] === 14 && version[1] < 15) ) { + // Error and exit if less than 12.13 or 13.x or less than 14.15 console.error( 'Node.js version ' + process.version +