Programming

(Windows) How to read input from console in a batch file?

steloflute 2013. 3. 14. 23:30

http://stackoverflow.com/questions/7879791/how-to-read-input-from-console-in-a-batch-file

 

The code snippet in the linked proposed duplicate reads user input.

ECHO A current build of Test Harness exists.
set /p delBuild=Delete preexisting build [y/n]?: 

 

The user can type as many letters as they want, and it will go into the delBuild variable.