ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From peter reilly <peter.rei...@corvil.com>
Subject Re: PROPOSE:optional nested filelist for available task
Date Tue, 03 Jun 2003 07:57:29 GMT
That should be "no source files" :-).
I should document this....

An example usage:
  <target name="t">
    <taskdef resource="net/sf/antcontrib/antcontrib.properties"/>
    <delete file="test.txt"/>
    <outofdate property="need.to.create">
      <sourcefiles/>
      <targetfiles>
        <filelist dir="${basedir}"
                  files="build.xml,test.txt"/>
      </targetfiles>
    </outofdate>
    <echo message="${need.to.create}"/>
    <touch file="test.txt"/>
    <outofdate property="no.need.to.create">
      <sourcefiles/>
      <targetfiles>
        <filelist dir="${basedir}"
                  files="build.xml,test.txt"/>
      </targetfiles>
    </outofdate>
    <echo message="${no.need.to.create}"/>
  </target>

Peter

On Friday 30 May 2003 23:17, Dominique Devienne wrote:
> I myself like quite a bit the <outofdate> task from Ant-Contrib by Peter
> Reilly... Also does away with Ant's pour if/unless conditions on targets to
> directly execute what needs to be done.
>
> Peter even added the ability to have no target files, and just source
> files, which are thus only checked for existence. Both source and target
> files accept a Path, and thus FileList. --DD
>
> > -----Original Message-----
> > From: Craeg Strong [mailto:cstrong@arielpartners.com]
> > Sent: Friday, May 30, 2003 4:10 PM
> > To: dev@ant.apache.org
> > Subject: PROPOSE:optional nested filelist for available task
> >
> >
> > Hello:
> >
> > A fellow ant user came to me with the following requirement:
> > perform packaging tasks if and only if the entire
> > set of some small number of known doc files was
> > present.
> >
> > If "available" could specify a filelist, then you
> > could explicitly list a set of files, all of which
> > _must_ be present in order to set a property.
> >
> > There may be other ways of fulfilling this particular
> > use case, but doesn't it make sense to extend
> > "available" in this way anyhow?  BTW, this would include
> > the regular "available" and the "available" inside
> > conditions.
> >
> > Thoughts?
> >
> > --Craeg
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
> > For additional commands, e-mail: dev-help@ant.apache.org
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
> For additional commands, e-mail: dev-help@ant.apache.org


Mime
View raw message