Hello Artur, You can achieve this with properties:
<java classname="..." failonerror="true"> <classpath> <pathelement location="..."/> </classpath> <arg value="-v" /> <arg value="${javaarg.t}" /> In your different maintasks (or property file) you do <property name="javaarg.t" value="-t"/> or <property name="javaarg.t" value=""/> or -- Greetings from good old Germany Jürgen -----Ursprüngliche Nachricht----- Von: Artur Rataj [mailto:arturra...@gmail.com] Gesendet: Freitag, 26. Juni 2009 11:50 An: user@ant.apache.org Betreff: How to distinguish build/clean and build within ant task Hello, I have asked this question on netbeans-users, but got no answer. I have a java task <java classname="..." failonerror="true"> <classpath> <pathelement location="..."/> </classpath> <arg value="-v" /> <arg value="-t" /> ... </java> I would like to include or exclude tags, depending on the main task. In this task, I would like to include the option -t only for netbeans' build task, and not for netbean's clean/build task. If possible, how could I do it? Best regards, Artur --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscr...@ant.apache.org For additional commands, e-mail: user-h...@ant.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscr...@ant.apache.org For additional commands, e-mail: user-h...@ant.apache.org