I would like to start a cmd line program in Batch and be able to communicate with it.
Currently I am starting the program with start /b cmd /c "cli_program.exe" > log.txt
. I am currently redirecting the output to a log file so that I can grep
findstr
the output.
Is there another way that I can get/send info to and from cli_program.exe
? For example, is there a way to watch the output and if everything works, send an ENTER
to proceed. or dynamically answer prompts coming from cli_program.exe
(not predefine them in a text file and passing that at start?)?