ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bill Rich" <b...@wilandra.com>
Subject RE: using arguments after the java command
Date Wed, 20 Jul 2005 01:51:47 GMT
See if this will help as a model --

<java classname="com.g11ntoolkit.tokenizer.TokListResourceBundle"
         fork="true"
         failonerror="true">
    <classpath refid="project.class.path"/>
        <jvmarg line="-Djava.util.logging.config.file=${LOGPROPS}"/>
        <arg line="/in${PRODUCT}/${file.name.src.@{afile}}"/>
        <arg line="/inloc${SOURCELOCALE}"/>
        <arg line="/str${PRODUCTWORKDIR}/${file.name.src.@{afile}}.str"/>
        <arg line="/context${file.name.src.@{afile}}"/>
        <arg line="/product${PRODUCT}"/>
        <arg line="/product-version${PRODUCT-VERSION}"/>
        </java>

The <jvmarg> element passes the arg to the JVM while the <arg> element
passes the arg to the target class.

HTH Bill 

-----Original Message-----
From: James Black [mailto:jblack@ieee.org] 
Sent: Tuesday, July 19, 2005 6:37 PM
To: user@ant.apache.org
Subject: re: using arguments after the java command

I am using ant 1.6.5

Here is the command I need to execute, and I would like to do this in ant,
as I think it could make life easier.

I don't know how to do the -f, -o and -d arguments after TINIConvertor, and
also, is there an easy way to put all the classes in my bin directory in the
argument prepended with a '-f'?

Thank you for any help.

java
-cp $TINI_HOME\tini.jar
TINIConvertor
-f bin\com\dtlab\zigbee\RadioBean.class
-f bin\com\dtlab\zigbee\DtLabSerialPort.class
-f bin\com\dtlab\zigbee\TiniSerialIO.class
-f bin\com\dtlab\basenode\BaseNodeMain.class
-o radar.tini -d $TINI_HOME\tini.db

Here is what I had attempted to do, but I got stuck with how to add
arguments after the java class that I am running.

<target name="maketini">
	<java classname="TINIConvertor"
		fork="true">
         <classpath>
           <pathelement location="${TINI_HOME}\bin\tini.jar"/>
           <pathelement path="${java.class.path}"/>
         </classpath>
	</java>
</target>


--
Corruptisima republica plurimae leges. [The more corrupt a republic, the
more laws.] Tacitus from Annals III, 116AD
Blogs: http://jamesruminations.blogspot.com

---------------------------------------------------------------------
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


Mime
View raw message