fix: Windows scripts check Node.js version, use winget OpenJS.NodeJS.V24

BAT and PS1 now detect if installed Node is < v24 and suggest/install
the correct v24 package instead of LTS (v22).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
delta-cloud-208e
2026-02-21 14:04:36 +00:00
parent 2c00e0327d
commit bb708e5650
2 changed files with 25 additions and 6 deletions

View File

@@ -31,9 +31,17 @@ if errorlevel 1 (
where node >nul 2>&1
if errorlevel 1 (
echo WARNING: Node.js not found. Updater will attempt to guide you.
echo Install: winget install OpenJS.NodeJS
echo WARNING: Node.js not found.
echo Install: winget install OpenJS.NodeJS.V24
echo or: https://nodejs.org/
) else (
for /f "tokens=1 delims=." %%A in ('node -v') do set "NODE_MAJOR=%%A"
set "NODE_MAJOR=!NODE_MAJOR:v=!"
if !NODE_MAJOR! LSS 24 (
echo WARNING: Node.js v!NODE_MAJOR! found, need v24+
echo Upgrade: winget install OpenJS.NodeJS.V24
echo or: https://nodejs.org/
)
)
REM ---- Pull latest artifacts ----