ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nasgowitz, Mark (MED, GEMS-IT)" <Mark.Nasgow...@med.ge.com>
Subject problem with exec and perl script getting input..
Date Tue, 10 Apr 2001 17:37:34 GMT
Overall I have ant working well. I would like to prompt the user to do a
manual task, then wait for the enter key. Perl script #1 works fine
while #2 hangs. Once ^c is pressed the keys pressed while the script
hangs are echoed back.

So the question is who controls STDIN? and how do I get it to my script.
Thanks!

build.xml
 <target name="runTest" depends="uploadCode" > 
   <exec executable="perl" failonerror="yes">
     <arg line="${utilDir}/${pauseScript}"/>
   </exec>
 </target>

1. THIS WORKS
pause.pl
 print "Press enter\n";

2. THIS FAILS
pause.pl
 print "Press enter\n";
 $_ = <STDIN>; 
 print "see ya: $_\n"; 

Mime
View raw message