You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by Catherine_iva <tm...@qip.ru> on 2010/10/20 12:42:35 UTC
Single input tag asking input twice
I have met an unexpected behaviour of ANT tool.
I have a task :
<target name="release-obf-signed" depends="release-obf">
<!-- Gets passwords -->
<input message="Please enter keystore password (store:${key.store}):"
addproperty="key.store.password" />
<input message="Please enter password for alias '${key.alias}':"
addproperty="key.alias.password" />
<echo>${key.store.password} ${key.alias.password}
${out.unsigned.package}</echo>
....
</target>
When flow reaches first <input> tag it waits for input twice: first time
with message "Please enter keystore password " , then, after pressing the
'Enter' for the second time, without any message, only after the second time
it sets property with the second entered value.
Why?
My enviroment :
ANT - Apache Ant version 1.7.1 compiled on October 20 2009
Android SDK Tools Revision 6, Platform Version: 1.6
JDK - Sun java version "1.6.0_22"
Java(TM) SE Runtime Environment (build 1.6.0_22-b04)
Thank you
Catherine
--
View this message in context: http://ant.1045680.n5.nabble.com/Single-input-tag-asking-input-twice-tp3228317p3228317.html
Sent from the Ant - Users mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org
Re: Single input tag asking input twice
Posted by glenn opdycke-hansen <gl...@gmail.com>.
try running with verbose flag on, -v.
Then scan for changes in the addproperty targets.
--glenn
On Wed, Oct 20, 2010 at 05:42, Catherine_iva <tm...@qip.ru> wrote:
>
> I have met an unexpected behaviour of ANT tool.
> I have a task :
> <target name="release-obf-signed" depends="release-obf">
> <!-- Gets passwords -->
> <input message="Please enter keystore password (store:${key.store}):"
> addproperty="key.store.password" />
>
> <input message="Please enter password for alias '${key.alias}':"
> addproperty="key.alias.password" />
>
> <echo>${key.store.password} ${key.alias.password}
> ${out.unsigned.package}</echo>
> ....
> </target>
>
> When flow reaches first <input> tag it waits for input twice: first time
> with message "Please enter keystore password " , then, after pressing the
> 'Enter' for the second time, without any message, only after the second
> time
> it sets property with the second entered value.
> Why?
>
> My enviroment :
> ANT - Apache Ant version 1.7.1 compiled on October 20 2009
> Android SDK Tools Revision 6, Platform Version: 1.6
> JDK - Sun java version "1.6.0_22"
> Java(TM) SE Runtime Environment (build 1.6.0_22-b04)
> Thank you
>
>
> Catherine
> --
> View this message in context:
> http://ant.1045680.n5.nabble.com/Single-input-tag-asking-input-twice-tp3228317p3228317.html
> Sent from the Ant - Users mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
> For additional commands, e-mail: user-help@ant.apache.org
>
>
RE: antcall
Posted by Jonathan Rosenberg <jr...@tabbysplace.org>.
What happens if you echo a constant string, instead of a variable
dereference?
--
Jonathan Rosenberg
Founder & Executive Director, Tabby's Place
http://www.tabbysplace.org/
-----Original Message-----
From: ext-simon.steiner@nokia.com [mailto:ext-simon.steiner@nokia.com]
Sent: Monday, October 25, 2010 11:49 AM
To: user@ant.apache.org
Subject: RE: antcall
ant test-1
> -----Original Message-----
> From: ext Jonathan Rosenberg [mailto:jr@tabbysplace.org]
> Sent: 25 October 2010 16:45
> To: 'Ant Users List'
> Subject: RE: antcall
>
> How are you "calling" test-1?
>
> --
> Jonathan Rosenberg
> Founder & Executive Director, Tabby's Place
> http://www.tabbysplace.org/
>
>
>
> -----Original Message-----
> From: ext-simon.steiner@nokia.com [mailto:ext-simon.steiner@nokia.com]
> Sent: Monday, October 25, 2010 11:42 AM
> To: user@ant.apache.org
> Subject: antcall
>
> Hi,
>
> How come if I call test-1, test-3 doesn't print ref2?
>
> <path id="ref1">
> <fileset dir="C:\Documents and Settings\x\Desktop "
> includes="a.xml"
> />
> </path>
> <path id="ref2">
> <fileset dir="C:\Documents and Settings\x\Desktop "
> includes="b.xml"
> />
> </path>
>
> <target name="test-1">
> <antcall target="test-2" inheritRefs="true">
> <reference refid="ref2" torefid="ref1" />
> </antcall>
> </target>
>
> <target name="test-2">
> <antcall target="test-3" inheritRefs="true"/>
> </target>
>
> <target name="test-3">
> <echo>${toString:ref1}</echo>
> </target>
>
> Thanks
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
> For additional commands, e-mail: user-help@ant.apache.org
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
> For additional commands, e-mail: user-help@ant.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org
RE: antcall
Posted by ex...@nokia.com.
ant test-1
> -----Original Message-----
> From: ext Jonathan Rosenberg [mailto:jr@tabbysplace.org]
> Sent: 25 October 2010 16:45
> To: 'Ant Users List'
> Subject: RE: antcall
>
> How are you "calling" test-1?
>
> --
> Jonathan Rosenberg
> Founder & Executive Director, Tabby's Place
> http://www.tabbysplace.org/
>
>
>
> -----Original Message-----
> From: ext-simon.steiner@nokia.com [mailto:ext-simon.steiner@nokia.com]
> Sent: Monday, October 25, 2010 11:42 AM
> To: user@ant.apache.org
> Subject: antcall
>
> Hi,
>
> How come if I call test-1, test-3 doesn't print ref2?
>
> <path id="ref1">
> <fileset dir="C:\Documents and Settings\x\Desktop "
> includes="a.xml"
> />
> </path>
> <path id="ref2">
> <fileset dir="C:\Documents and Settings\x\Desktop "
> includes="b.xml"
> />
> </path>
>
> <target name="test-1">
> <antcall target="test-2" inheritRefs="true">
> <reference refid="ref2" torefid="ref1" />
> </antcall>
> </target>
>
> <target name="test-2">
> <antcall target="test-3" inheritRefs="true"/>
> </target>
>
> <target name="test-3">
> <echo>${toString:ref1}</echo>
> </target>
>
> Thanks
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
> For additional commands, e-mail: user-help@ant.apache.org
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
> For additional commands, e-mail: user-help@ant.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org
RE: antcall
Posted by Jonathan Rosenberg <jr...@tabbysplace.org>.
How are you "calling" test-1?
--
Jonathan Rosenberg
Founder & Executive Director, Tabby's Place
http://www.tabbysplace.org/
-----Original Message-----
From: ext-simon.steiner@nokia.com [mailto:ext-simon.steiner@nokia.com]
Sent: Monday, October 25, 2010 11:42 AM
To: user@ant.apache.org
Subject: antcall
Hi,
How come if I call test-1, test-3 doesn't print ref2?
<path id="ref1">
<fileset dir="C:\Documents and Settings\x\Desktop " includes="a.xml"
/>
</path>
<path id="ref2">
<fileset dir="C:\Documents and Settings\x\Desktop " includes="b.xml"
/>
</path>
<target name="test-1">
<antcall target="test-2" inheritRefs="true">
<reference refid="ref2" torefid="ref1" />
</antcall>
</target>
<target name="test-2">
<antcall target="test-3" inheritRefs="true"/>
</target>
<target name="test-3">
<echo>${toString:ref1}</echo>
</target>
Thanks
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org
antcall
Posted by ex...@nokia.com.
Hi,
How come if I call test-1, test-3 doesn't print ref2?
<path id="ref1">
<fileset dir="C:\Documents and Settings\x\Desktop " includes="a.xml" />
</path>
<path id="ref2">
<fileset dir="C:\Documents and Settings\x\Desktop " includes="b.xml" />
</path>
<target name="test-1">
<antcall target="test-2" inheritRefs="true">
<reference refid="ref2" torefid="ref1" />
</antcall>
</target>
<target name="test-2">
<antcall target="test-3" inheritRefs="true"/>
</target>
<target name="test-3">
<echo>${toString:ref1}</echo>
</target>
Thanks
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org
Re: Single input tag asking input twice
Posted by Catherine_i <je...@yahoo.com>.
Hi Stefan Bodewig!
Yes, I have <java> task before and adding inputstring="" attribute to that
task fixed the problem.
Thank you!
Thank you everybody!
Catherine
--
View this message in context: http://ant.1045680.n5.nabble.com/Single-input-tag-asking-input-twice-tp3228317p3235536.html
Sent from the Ant - Users mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org
Re: Single input tag asking input twice
Posted by Stefan Bodewig <bo...@apache.org>.
On 2010-10-20, Catherine_iva wrote:
> When flow reaches first <input> tag it waits for input twice: first time
> with message "Please enter keystore password " , then, after pressing the
> 'Enter' for the second time, without any message, only after the second time
> it sets property with the second entered value.
Is there any foked <java> task or <exec> task running before you reach
that <input> task? If so, bugzilla issue 49119 may be the culprit
<https://issues.apache.org/bugzilla/show_bug.cgi?id=49119>.
As a workaround you should add inputstring="" to any forked <java> or
<exec> task preceeding your <input>.
Stefan
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org