diff options
author | João Reis <reis@janeasystems.com> | 2018-10-31 00:52:35 +0000 |
---|---|---|
committer | Rich Trott <rtrott@gmail.com> | 2018-11-03 19:35:39 -0700 |
commit | ab2778d76368c240764c931404fa3c7f25aaa309 (patch) | |
tree | 145e6c95a46547cec796e7c30eecda5b0b3790b4 /tools | |
parent | 5833fa989d8c724ad76a912bc402c6843f177328 (diff) | |
download | node-new-ab2778d76368c240764c931404fa3c7f25aaa309.tar.gz |
win: add prompt to tools installation script
Fixes: https://github.com/nodejs/Release/issues/369
PR-URL: https://github.com/nodejs/node/pull/23987
Reviewed-By: John-David Dalton <john.david.dalton@gmail.com>
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Diffstat (limited to 'tools')
-rw-r--r-- | tools/msvs/install_tools/install_tools.bat | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/tools/msvs/install_tools/install_tools.bat b/tools/msvs/install_tools/install_tools.bat index 1585b5b7c9..36456fa6f6 100644 --- a/tools/msvs/install_tools/install_tools.bat +++ b/tools/msvs/install_tools/install_tools.bat @@ -1,5 +1,7 @@ @echo off +setlocal + cls echo ==================================================== echo Tools for Node.js Native Modules Installation Script @@ -61,9 +63,14 @@ echo. echo Sometimes the scripts may install all necessary Windows Updates which echo could cause a high number of reboots that appear to be a reboot loop when echo in fact it is just a normal Windows Updates reboot cycle. +:acceptretry echo. -echo If this is not what you would like to occur, you can close this window -echo to stop now. -pause +echo Your computer may REBOOT SEVERAL TIMES WITHOUT FURTHER WARNING. +echo Please type YES followed by enter to confirm that you have saved all your +set /p "ACCEPT_PROMPT=work and closed all open programs: " +if /i not "%ACCEPT_PROMPT%"=="yes" ( + echo Please type YES to confirm, or close the window to exit. + goto acceptretry +) "%SystemRoot%\System32\WindowsPowerShell\v1.0\powershell.exe" -NoProfile -InputFormat None -ExecutionPolicy Bypass -Command Start-Process '%SystemRoot%\System32\WindowsPowerShell\v1.0\powershell.exe' -ArgumentList '-NoProfile -InputFormat None -ExecutionPolicy Bypass -Command iex ((New-Object System.Net.WebClient).DownloadString(''https://boxstarter.org/bootstrapper.ps1'')); get-boxstarter -Force; Install-BoxstarterPackage -PackageName ''%~dp0\install_tools.txt''; Read-Host ''Type ENTER to exit'' ' -Verb RunAs |