Also forgot to mention that this could also be set in ANT_ARGS if one wanted
On Tue, 12 Oct 2004 07:58:54 -0400, steve morin <[EMAIL PROTECTED]> wrote:
> Jan and Peter to answer your questions I have a couple of scenarios
> where this could be useful.
>
> 1st usage convenience..
> A person that often uses a different build file could use a shell
> script that calls ant using a different default for convenience.
>
> #!/bin/sh
> ant -df config.xml "$@"
>
> or
> alias cfg="ant -df config.xml"
>
> 2nd usage dynamic change of ant task default target.
>
> >> Ant
> >> Description
> >>
> >> Runs Ant on a supplied buildfile. This can be used to build
> subprojects. This task must not be used outside of a target if it
> invokes the same build file it is part of.
> >>
> >> When the antfile attribute is omitted, the file "build.xml" in the
> supplied directory (dir attribute) is used.
>
> 3rd usage dynamic change of subant task calls
>
> >> antfile Build file name, to use in conjunction with
> directories. String Optional
> >> Defaults to "build.xml".
> >> If genericantfile is set, this attribute is ignored.
>
> Of the three usages I believe the 1st and 3rd usages have the most
> merit. I believe the 1st could be very beneficial to many people to
> speed development. It's a minor changes and requires little
> maintenance but increases flexibility greatly. Dynamic usage of
> subant would great to simplify ant usage for projects that multiple
> preprocess.
>
> --build.xml
> <project name="subant" default="subant1">
> <property name="build.dir" value="subant.build"/>
> <target name="subant1">
> <subant target="" buildpath="${project.dir}>
> <property name="build.dir" value="subant1.build"/>
> <property name="not.overloaded" value="not.overloaded"/>
>
> </subant>
> </target>
> </project>
>
> --bashrc
> alias doc="and -df docs.xml"
> alias gen="ant -df generate.xml"
> alias cfg="ant -df config.xml"
>
> cmd: gen -f build.xml
> cmd: cfg -f build.xml
> cmd: ant
>
>
> Why doing that?
> ant -f other.xml
> would work.
>
> Jan
>
> The patch did not get tru the mailing list.
> Open a bugzilla report for the patch.
> How would this patch be useful?
>
> Peter
> - Hide quoted text -
> steve morin wrote:
>
> >This patch allowes people to set the default filename that ant uses if
> >none is given and sets ant.file.default to default file name value.
> >
> >M docs/manual/running.html
> >M docs/manual/using.html
> >M src/main/org/apache/tools/ant/Main.java
> >M src/main/org/apache/tools/ant/taskdefs/Ant.java
> >M src/main/org/apache/tools/ant/taskdefs/SubAnt.java
> >
> >I would have provided unit tests with this and would appreciate some
> >one pointing me in the right direction so I can create them.
> >
> >
> >
>
>
> On Mon, 11 Oct 2004 12:04:28 +0200, [EMAIL PROTECTED]
>
>
> <[EMAIL PROTECTED]> wrote:
> > Why doing that?
> > ant -f other.xml
> > would work.
> >
> > Jan
> >
> > > -----Urspr�ngliche Nachricht-----
> > > Von: Peter Reilly [mailto:[EMAIL PROTECTED]
> > > Gesendet am: Montag, 11. Oktober 2004 10:50
> > > An: Ant Developers List
> > > Betreff: Re: [PATCH] set filename of default buildfile
> > >
> > > The patch did not get tru the mailing list.
> > > Open a bugzilla report for the patch.
> > > How would this patch be useful?
> > >
> > > Peter
> > > steve morin wrote:
> > >
> > > >This patch allowes people to set the default filename that
> > > ant uses if
> > > >none is given and sets ant.file.default to default file name value.
> > > >
> > > >M docs/manual/running.html
> > > >M docs/manual/using.html
> > > >M src/main/org/apache/tools/ant/Main.java
> > > >M src/main/org/apache/tools/ant/taskdefs/Ant.java
> > > >M src/main/org/apache/tools/ant/taskdefs/SubAnt.java
> > > >
> > > >I would have provided unit tests with this and would appreciate some
> > > >one pointing me in the right direction so I can create them.
> > > >
> > > >
> > > >
> > > >-------------------------------------------------------------
> > > -----------
> > > >
> > > >---------------------------------------------------------------------
> > > >To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > >For additional commands, e-mail: [EMAIL PROTECTED]
> > > >
> > >
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > For additional commands, e-mail: [EMAIL PROTECTED]
> > >
> >
> >
>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]