ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Manav Ahuja" <>
Subject RE: Command Line Argument
Date Tue, 26 Aug 2003 07:34:19 GMT
This I am aware,  but may be then I couldn't put the requirement correctly...
  I want the user when running the "build.xml" specify
Ant -buildfile build.xml compile
Ant -buildfile build.xml Get
Ant -buildfile build.xml Rmic
Etc etc..

Hope now it is clear..And if I put the same into the targets can I do this demarcation
  means say I am fixing some bug and so I have changed some ten java files and so finally
only one or two jars will change. These java files donot need rmic..
  So what I want is that I run the "build.xml" file as

Ant -buildfile build.xml Get
Ant -buildfile build.xml Compile.

  Since it doesnot need any other steps ..thats it. Since it is affecting only one jar so
I will create that manually and check...

Hope am clear this time ..
Any suggestions..


-----Original Message-----
From: [] 
Sent: Tuesday, August 26, 2003 12:25 PM
Subject: RE: Command Line Argument

Divide your buildfile in several targets. That´s why they are there. :-) You can use target´s
'depends' clause for ensuring that a needed step is done before.

<project main="full">
    <target name="vssupdate" description="gets the latest from the VSS">
        <!-- your code for VSS update goes here -->
    <target name="compile" description="Compiles the whole code"/>
    <target name="stubs" description="Creates the stubs and skeletons" depends="compile"/>
    <target name="jar" description="Makes jars" depends="stubs"/>    
    <target name="copy" description="Copies the jars and some more files into a new folder"
    <target name="falg" description="Replace the Falg inside 2 files"/>
    <target name="full" description="update and complete build" depends="vssupdate,copy,falg"/>

I was working on the Wiki some minutes ago, maybe
would interest you.


> -----Original Message-----
> From: Manav Ahuja []
> Sent: Tuesday, August 26, 2003 8:41 AM
> To: Ant Users List
> Subject: Command Line Argument
> Currently I am having ONE "build.xml" file. This file has ONE target 
> inside that various tasks are accomplished. Tasks are: 1. It gets the 
> latest from the VSS. 2. Compiles the whole code.
> 3. Creates the stubs and skeletons.
> 4. Makes jars
> 5. Copies the jars and some more files(Properties and batch 
> etc) into a
> new folder.
> 6. Replace the Falg inside 2 files.
> Now my Issue is I am successful in the above in no time.
> Still I want to
> automate further. Is there any utility provided in ant so that when I
> run the "build.xml" in the command line itself I specify, means I can
> demarcate the 6 steps above according to what I want for example :
> A) Get ---  to get the latest from VSS
> B) Compile -- to compile
> C) rmic -- to create the stubs and skeletons
>   n so on and so forth.
> Any light is heartedly welcome........
> Thankx In Advance,
> Manav
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message