ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Sobremonte <mich...@redshift.co.za>
Subject "Failed to read input from Console" Error invoking ant from java class
Date Mon, 15 Dec 2008 13:34:51 GMT
Hi

I am trying to call an ant target requiring input from within a java class.

My build file is menu-based so it jumps from menu to menu depending on
the input.

The problem is as soon as input is entered in INPUT MENU 1,
The next menu will fail to read input.

eg:

# INPUT MENU 1:
<input message="Select an option:"  validargs="1,2,X"
addproperty="main.option"/>

# INPUT MENU 2:
<input message="Select an option:" validargs="Y,N"
addproperty="abort.option"/>

In the above example, as soon as "X" is entered for INPUT MENU 1 and the
INPUT MENU 2 message is displayed,
ant will fail with a "Failed to read input from Console." message
pointing to the the INPUT MENU 2 line.

My AntInvoker class is similiar to the example in:
http://www.ibm.com/developerworks/websphere/library/techarticles/0502_gawor/0502_gawor.html

Thanks for any input.

Cheers,
Michael

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message