simulating console input

Bengt-Arne Fjellner Bengt-Arne.Fjellner@ltu.se
Thu Sep 2 13:44:00 GMT 2010


  On 2010-09-02 9:47 AM, Peter Münster wrote:
> Hello,
>
> I would like to run a Dos program, that needs keyboard input (just one "Y"),
> automatically via "make" in an ssh-session.
>
> How could I simulate the "Y" keypress?
>
> "echo Y | DosProgram.exe"
>   does not work...
>
> The keypress is accepted only in a dos-console.
>
> TIA for any help!
> Peter
>
Does "echo Y | DosProgram.exe" work in a cmd window?
If so it should be possible to do something like (untested)
cmd /c echo Y | pgm


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple



More information about the Cygwin mailing list