X-Recipient: archive-cygwin AT delorie DOT com X-SWARE-Spam-Status: No, hits=-2.1 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_LOW,TW_PG,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Message-ID: <4C7FAA42.8020909@ltu.se> Date: Thu, 02 Sep 2010 15:44:34 +0200 From: Bengt-Arne Fjellner User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-GB; rv:1.9.2.9) Gecko/20100825 Thunderbird/3.1.3 MIME-Version: 1.0 To: cygwin AT cygwin DOT com Subject: Re: simulating console input References: <20100902074703 DOT GA11464 AT gaston DOT couberia DOT bzh> In-Reply-To: <20100902074703.GA11464@gaston.couberia.bzh> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com 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